> From: Jim Wilson <wil...@codesourcery.com>
> To: Jamie Prescott <jpre...@yahoo.com>
> Cc: Georg-Johann Lay <a...@gjlay.de>; Ian Lance Taylor <i...@google.com>; 
> gcc@gcc.gnu.org
> Sent: Tuesday, May 26, 2009 7:47:45 PM
> Subject: Re: Seeking suggestion
> 
> Jamie Prescott wrote:
> > Is there a reason why something like this would not work?
> >     if (!TARGET_XXX2)
> >       emit_clobber(gen_rtx_REG(CCmode, CC_REGNUM));
> >     emit_insn(gen_addsi3_nc(operands[0], operands[1], operands[2]));
> 
> Yes.  The optimizer will not know that addsi3_nc uses CC_REGNUM, as it is not 
> mentioned, so the optimizer will not know that these two RTL instructions 
> always 
> need to remain next to each other.  Any optimization pass that moves insns 
> around may separate the add from the clobber resulting in broken code.  This 
> is 
> what parallels are for, to make sure that the clobber and add stay together.

Thanks for the explanation. I somehow thought that every insn spit out by a 
define_insn
was automatically turned into a parallel.
I guess I was wrong.


- Jamie


      

Reply via email to