From cdebbc6d8dcade8634ca18060205f2065bb9973f Mon Sep 17 00:00:00 2001 From: Jakub Jelinek Date: Sun, 24 Feb 2013 19:54:37 +0100 Subject: [PATCH] re PR target/52555 (ICE unrecognizable insn with -ffast-math and __attribute__((optimize(xx)))) PR target/52555 * target-globals.c (save_target_globals): For init_reg_sets and target_reinit remporarily set this_fn_optabs to this_target_optabs. From-SVN: r196245 --- gcc/ChangeLog | 6 ++++++ gcc/target-globals.c | 3 +++ 2 files changed, 9 insertions(+) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index fda14f3cb7e..ca97c8a7be5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2013-02-24 Jakub Jelinek + + PR target/52555 + * target-globals.c (save_target_globals): For init_reg_sets and + target_reinit remporarily set this_fn_optabs to this_target_optabs. + 2013-02-22 James Grennahlgh * config/aarch64/aarch64-simd-builtins.def: Add copyright header. diff --git a/gcc/target-globals.c b/gcc/target-globals.c index d72495da26d..65ccb8af5e6 100644 --- a/gcc/target-globals.c +++ b/gcc/target-globals.c @@ -67,6 +67,7 @@ struct target_globals * save_target_globals (void) { struct target_globals *g; + struct target_optabs *saved_this_fn_optabs = this_fn_optabs; g = ggc_alloc_target_globals (); g->flag_state = XCNEW (struct target_flag_state); @@ -86,8 +87,10 @@ save_target_globals (void) g->bb_reorder = XCNEW (struct target_bb_reorder); g->lower_subreg = XCNEW (struct target_lower_subreg); restore_target_globals (g); + this_fn_optabs = this_target_optabs; init_reg_sets (); target_reinit (); + this_fn_optabs = saved_this_fn_optabs; return g; }