On 8/25/05, Ashwin Kolhe <[EMAIL PROTECTED]> wrote:
> > You'll have something like this in your test
> >
> > operands[0] == operands[1] || peep2_regno_dead_p (2, operands[0])
> >
> > i.e. you only need to test for op0's death if it is different from op1.
> >
> > Paolo
> >
> 
> Exactly.. this is the same thing as calling dead_or_set_p(insn,
> operands[0]). 


i am sorry, since we are using peephole2, the variable "insn" points
to the first insn in the template and not the last. so the call should
be
dead_or_set_p(next_nonnote_insn(insn),operands[0])


> If it can be done by dead_or_set_p, why use
> peep2_dead_reg_p? Other ports also support the use of peep2_dead_reg_p
> instead of dead_or_set_p. What is the basic difference between the
> two? I mean, there must be something the former can do which the
> latter can't.
> 
> Please correct me if i am wrong.
> 
> Thanks in advance,
> Ashwin.
>

Reply via email to