From ee24c8e14ec3473b066a460eb8eef38a3fa91e23 Mon Sep 17 00:00:00 2001 From: Eric Botcazou Date: Mon, 2 Jul 2018 10:15:42 +0000 Subject: [PATCH] i386.c (ix86_finalize_stack_frame_flags): Do not overrule -fno-omit-frame-pointer when not optimizing. * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule -fno-omit-frame-pointer when not optimizing. From-SVN: r262302 --- gcc/ChangeLog | 9 +++++++-- gcc/config/i386/i386.c | 2 +- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 5c1b097c2af..5bf5ce244a5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2018-07-02 Eric Botcazou + + * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule + -fno-omit-frame-pointer when not optimizing. + 2018-07-02 Martin Liska PR ipa/86279 @@ -394,6 +399,8 @@ 2018-06-28 Eric Botcazou + * tree-inline.h (struct copy_body_data): Move remapping_type_depth and + prevent_decl_creation_for_types fields up and add reset_location field. * tree-inline.c (remap_gimple_stmt): Force input_location on the new statement if id->reset_location is true. (copy_edges_for_bb): Do not set goto_locus on the new edges if @@ -402,8 +409,6 @@ id->reset_location is true. (expand_call_inline): Set id->reset_location if DECL_IGNORED_P is set on the function to be inlined. - * tree-inline.h (struct copy_body_data): Move remapping_type_depth and - prevent_decl_creation_for_types fields up and add reset_location field. 2018-06-27 Stephan Bergmann diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index ba23cd0a1ab..e6d17632142 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -13145,7 +13145,7 @@ ix86_finalize_stack_frame_flags (void) is used, but in the end nothing that needed the stack alignment had been spilled nor stack access, clear frame_pointer_needed and say we don't need stack realignment. */ - if ((stack_realign || !flag_omit_frame_pointer) + if ((stack_realign || (!flag_omit_frame_pointer && optimize)) && frame_pointer_needed && crtl->is_leaf && crtl->sp_is_unchanging -- 2.30.2