aboutsummaryrefslogtreecommitdiff
path: root/gcc/reginfo.c
diff options
context:
space:
mode:
authorBernd Schmidt <bernds@redhat.com>2016-05-03 09:35:42 +0000
committerBernd Schmidt <bernds@gcc.gnu.org>2016-05-03 09:35:42 +0000
commitf80041efb991e4326971dea550157192f912d9a4 (patch)
treedb4f856ef821d7dc564edeb431dc0da7bf076b30 /gcc/reginfo.c
parent1cfcd39eee915a7582adc113fa6e7faac8b943e4 (diff)
downloadgcc-f80041efb991e4326971dea550157192f912d9a4.zip
gcc-f80041efb991e4326971dea550157192f912d9a4.tar.gz
gcc-f80041efb991e4326971dea550157192f912d9a4.tar.bz2
Fix PR44281, bad RA with global regs.
PR rtl-optimization/44281 * hard-reg-set.h (struct target_hard_regs): New field x_fixed_nonglobal_reg_set. (fixed_nonglobal_reg_set): New macro. * reginfo.c (init_reg_sets_1): Initialize it. * ira.c (setup_alloc_regs): Use fixed_nonglobal_reg_set instead of fixed_reg_set. * df-scan.c (df_insn_refs_collect): Asms may reference global regs. testsuite/ PR rtl-optimization/44281 * gcc.target/i386/pr44281.c: New test. From-SVN: r235809
Diffstat (limited to 'gcc/reginfo.c')
-rw-r--r--gcc/reginfo.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/reginfo.c b/gcc/reginfo.c
index ccf53bf..f4dac08 100644
--- a/gcc/reginfo.c
+++ b/gcc/reginfo.c
@@ -449,6 +449,7 @@ init_reg_sets_1 (void)
}
COPY_HARD_REG_SET (call_fixed_reg_set, fixed_reg_set);
+ COPY_HARD_REG_SET (fixed_nonglobal_reg_set, fixed_reg_set);
/* Preserve global registers if called more than once. */
for (i = 0; i < FIRST_PSEUDO_REGISTER; i++)