re PR rtl-optimization/53373 (ICE on valid code with -mavx)

PR rtl-optimization/53373
	* caller-save.c (save_call_clobbered_regs): Look into a possible
	PARALLEL manually rather than using single_set on a call insn.

From-SVN: r187745
This commit is contained in:
Bernd Schmidt 2012-05-21 21:37:01 +00:00 committed by Bernd Schmidt
parent a9a587118e
commit 1d2944a3fe
2 changed files with 13 additions and 5 deletions

View File

@ -1,3 +1,9 @@
2012-05-21 Bernd Schmidt <bernds@codesourcery.com>
PR rtl-optimization/53373
* caller-save.c (save_call_clobbered_regs): Look into a possible
PARALLEL manually rather than using single_set on a call insn.
2012-05-21 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/53436

View File

@ -872,11 +872,13 @@ save_call_clobbered_regs (void)
&& HARD_REGISTER_P (cheap)
&& TEST_HARD_REG_BIT (call_used_reg_set, REGNO (cheap)))
{
rtx call_set = single_set (insn);
rtx dest = SET_DEST (call_set);
rtx pat = gen_rtx_SET (VOIDmode, cheap,
copy_rtx (dest));
chain = insert_one_insn (chain, 0, -1, pat);
rtx dest, newpat;
rtx pat = PATTERN (insn);
if (GET_CODE (pat) == PARALLEL)
pat = XVECEXP (pat, 0, 0);
dest = SET_DEST (pat);
newpat = gen_rtx_SET (VOIDmode, cheap, copy_rtx (dest));
chain = insert_one_insn (chain, 0, -1, newpat);
}
}
last = chain;