[llvm-commits] [llvm] r42699 - /llvm/trunk/lib/Target/X86/X86RegisterInfo.cpp

Chris Lattner clattner at apple.com
Sat Oct 6 19:03:09 PDT 2007


> URL: http://llvm.org/viewvc/llvm-project?rev=42699&view=rev
> Log:
> Move merge code into new helper function.

Nice:

> +// mergeSPUpdatesUp - Merge two stack-manipulating instructions  
> upper iterator.
> +static
> +void mergeSPUpdatesUp(MachineBasicBlock &MBB,  
> MachineBasicBlock::iterator &MBBI,
> +                      unsigned StackPtr, uint64_t *NumBytes = NULL) {
> +  if (MBBI != MBB.begin()) {

How about starting this out with:

if (MBBI == MBB.begin()) return;

to unnest the function body one level?

-Chris






More information about the llvm-commits mailing list