reload1.c:eliminate_regs_in_insn bugfix
Joern Rennecke
amylaar@redhat.com
Wed Oct 25 11:45:00 GMT 2000
Wed Oct 25 19:43:04 2000 J"orn Rennecke <amylaar@redhat.com>
* reload1.c (eliminate_regs_in_insn): Allow a set to be a PARALLEL
with (clobber (match_scratch...)).
Index: reload1.c
===================================================================
RCS file: /cvs/cvsfiles/devo/gcc/reload1.c,v
retrieving revision 1.277
diff -p -r1.277 reload1.c
*** reload1.c 2000/10/16 22:11:01 1.277
--- reload1.c 2000/10/25 18:40:52
*************** eliminate_regs_in_insn (insn, replace)
*** 2945,2957 ****
if (offset == 0)
{
! /* We assume here that we don't need a PARALLEL of
! any CLOBBERs for this assignment. There's not
! much we can do if we do need it. */
PATTERN (insn) = gen_rtx_SET (VOIDmode,
SET_DEST (old_set),
ep->to_rtx);
! INSN_CODE (insn) = recog (PATTERN (insn), insn, 0);
if (INSN_CODE (insn) < 0)
abort ();
}
--- 2946,2971 ----
if (offset == 0)
{
! int num_clobbers;
! /* We assume here that if we need a PARALLEL with
! CLOBBERs for this assignment, we can do with the
! MATCH_SCRATCHes that add_clobbers allocates.
! There's not much we can do if that doesn't work. */
PATTERN (insn) = gen_rtx_SET (VOIDmode,
SET_DEST (old_set),
ep->to_rtx);
! num_clobbers = 0;
! INSN_CODE (insn) = recog (PATTERN (insn), insn, &num_clobbers);
! if (num_clobbers)
! {
! PATTERN (insn)
! = gen_rtx_PARALLEL (VOIDmode,
! gen_rtvec (num_clobbers + 1,
! PATTERN (insn)));
! add_clobbers (PATTERN (insn), INSN_CODE (insn));
! if (extract_insn (insn), ! constrain_operands (1))
! abort ();
! }
if (INSN_CODE (insn) < 0)
abort ();
}
More information about the Gcc-patches
mailing list