python/hypothesis: update to 6.122.3
[oi-userland.git] / components / developer / gcc-12 / patches / 0012-We-never-want-to-omit-the-frame-pointer-regardless-o.patch
blobb36f1de10cdd982ce1e2ee0b128fc8edd7624ce9
1 From 5b3c03701632aa2b971f1abf7238c760fd876cf2 Mon Sep 17 00:00:00 2001
2 From: Andy Fiddaman <omnios@citrus-it.co.uk>
3 Date: Thu, 25 Oct 2018 18:19:36 +0000
4 Subject: We never want to omit the frame pointer, regardless of
5 the optimisation level or options to gcc - we like stack traces too much and
6 it is of questionable benefit anyway, even on i386.
8 ---
9 gcc/config/i386/i386-options.cc | 9 +++++++++
10 gcc/opts.cc | 3 ++-
11 2 files changed, 11 insertions(+), 1 deletion(-)
13 diff --git a/gcc/config/i386/i386-options.cc b/gcc/config/i386/i386-options.cc
14 index a26cb878b68..c7d72023f77 100644
15 --- a/gcc/config/i386/i386-options.cc
16 +++ b/gcc/config/i386/i386-options.cc
17 @@ -2914,6 +2914,15 @@ ix86_option_override_internal (bool main_args_p,
18 free (str);
21 + /*
22 + * We never want to omit the frame pointer, regardless of the optimisation
23 + * level or options to gcc - we like stack traces too much and it is of
24 + * questionable benefit anyway, even on i386.
25 + */
27 + flag_omit_frame_pointer = 0;
28 + opts->x_flag_omit_frame_pointer = 0;
30 /* Save the initial options in case the user does function specific
31 options. */
32 if (main_args_p)
33 diff --git a/gcc/opts.cc b/gcc/opts.cc
34 index a97630d1c9a..d40c92456ed 100644
35 --- a/gcc/opts.cc
36 +++ b/gcc/opts.cc
37 @@ -573,7 +573,7 @@ static const struct default_options default_options_table[] =
38 { OPT_LEVELS_1_PLUS, OPT_fipa_reference, NULL, 1 },
39 { OPT_LEVELS_1_PLUS, OPT_fipa_reference_addressable, NULL, 1 },
40 { OPT_LEVELS_1_PLUS, OPT_fmerge_constants, NULL, 1 },
41 - { OPT_LEVELS_1_PLUS, OPT_fomit_frame_pointer, NULL, 1 },
42 + { OPT_LEVELS_1_PLUS, OPT_fomit_frame_pointer, NULL, 0 },
43 { OPT_LEVELS_1_PLUS, OPT_freorder_blocks, NULL, 1 },
44 { OPT_LEVELS_1_PLUS, OPT_fshrink_wrap, NULL, 1 },
45 { OPT_LEVELS_1_PLUS, OPT_fsplit_wide_types, NULL, 1 },
46 @@ -609,6 +609,7 @@ static const struct default_options default_options_table[] =
47 { OPT_LEVELS_1_PLUS_NOT_DEBUG, OPT_ftree_pta, NULL, 1 },
48 { OPT_LEVELS_1_PLUS_NOT_DEBUG, OPT_ftree_sra, NULL, 1 },
51 /* -O2 and -Os optimizations. */
52 { OPT_LEVELS_2_PLUS, OPT_fcaller_saves, NULL, 1 },
53 { OPT_LEVELS_2_PLUS, OPT_fcode_hoisting, NULL, 1 },