[llvm-commits] Intel Atom optimization - use LEA to adjust stack pointer

Zhang, Andy andy.zhang at intel.com
Tue Jan 3 08:45:15 PST 2012


On Friday, December 23, 2011 11:06 PM, Jakob Stoklund Olesen wrote:

> Hi Andy,
> 
> Please submit the TableGen changes as an independent patch.
> 
> From a quick glance, you also need to make sure you follow LLVM's style
> for braces etc.
> 
>      if (isSub)
> +    {
>        MI->setFlag(MachineInstr::FrameSetup);
> -    MI->getOperand(3).setIsDead(); // The EFLAGS implicit def is dead.
> +    }
> 
> Why add braces here?
> 
> /jakob

Hi Jakob,

I'll submit the TableGen part of the patch separately.

I put braces there in case another line is added to the body of the if-statement in
the future and the braces are accidentally overlooked. But they should be on the previous
line anyway.

I can remove the braces from all of the single-statement if-blocks that I added, for
consistency with the rest of that file.

Regards,
Andy





More information about the llvm-commits mailing list