diff options
author | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2013-10-25 09:21:11 +0000 |
---|---|---|
committer | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2013-10-25 09:21:11 +0000 |
commit | 356610cb478784b55aeb9936f1611de5b0d27e70 (patch) | |
tree | 3eae639e031fb1f449c90e31952e47635f27c796 /gcc/alias.c | |
parent | 2e30c7fbc4eb5a58caae9fd2ed1cd05b60bdcec5 (diff) | |
download | gcc-356610cb478784b55aeb9936f1611de5b0d27e70.tar.gz |
re PR rtl-optimization/58831 (wrong code at -O2 and -O3 on x86_64-linux-gnu in 64-bit mode)
PR rtl-optimization/58831
* alias.c (init_alias_analysis): At the beginning of each iteration, set
the reg_seen[N] bit if static_reg_base_value[N] is non-null.
From-SVN: r204055
Diffstat (limited to 'gcc/alias.c')
-rw-r--r-- | gcc/alias.c | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/gcc/alias.c b/gcc/alias.c index 0f9ae73e3d2..1736169b476 100644 --- a/gcc/alias.c +++ b/gcc/alias.c @@ -2975,16 +2975,13 @@ init_alias_analysis (void) /* Wipe the reg_seen array clean. */ bitmap_clear (reg_seen); - /* Mark all hard registers which may contain an address. - The stack, frame and argument pointers may contain an address. - An argument register which can hold a Pmode value may contain - an address even if it is not in BASE_REGS. - - The address expression is VOIDmode for an argument and - Pmode for other registers. */ - - memcpy (new_reg_base_value, static_reg_base_value, - FIRST_PSEUDO_REGISTER * sizeof (rtx)); + /* Initialize the alias information for this pass. */ + for (i = 0; i < FIRST_PSEUDO_REGISTER; i++) + if (static_reg_base_value[i]) + { + new_reg_base_value[i] = static_reg_base_value[i]; + bitmap_set_bit (reg_seen, i); + } /* Walk the insns adding values to the new_reg_base_value array. */ for (i = 0; i < rpo_cnt; i++) |