[llvm-commits] [llvm] r58523 - in /llvm/trunk/lib: CodeGen/PrologEpilogInserter.cpp Target/X86/X86RegisterInfo.cpp
Bill Wendling
isanbard at gmail.com
Fri Oct 31 11:30:19 PDT 2008
Author: void
Date: Fri Oct 31 13:30:19 2008
New Revision: 58523
URL: http://llvm.org/viewvc/llvm-project?rev=58523&view=rev
Log:
Revert r58489. It isn't correct for all cases.
Modified:
llvm/trunk/lib/CodeGen/PrologEpilogInserter.cpp
llvm/trunk/lib/Target/X86/X86RegisterInfo.cpp
Modified: llvm/trunk/lib/CodeGen/PrologEpilogInserter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/PrologEpilogInserter.cpp?rev=58523&r1=58522&r2=58523&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/PrologEpilogInserter.cpp (original)
+++ llvm/trunk/lib/CodeGen/PrologEpilogInserter.cpp Fri Oct 31 13:30:19 2008
@@ -273,10 +273,10 @@
MBB = FI;
I = MBB->end(); --I;
- // Skip over all "return" instructions, which are part of the return
+ // Skip over all terminator instructions, which are part of the return
// sequence.
MachineBasicBlock::iterator I2 = I;
- while (I2 != MBB->begin() && (--I2)->getDesc().isReturn())
+ while (I2 != MBB->begin() && (--I2)->getDesc().isTerminator())
I = I2;
bool AtStart = I == MBB->begin();
Modified: llvm/trunk/lib/Target/X86/X86RegisterInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86RegisterInfo.cpp?rev=58523&r1=58522&r2=58523&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86RegisterInfo.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86RegisterInfo.cpp Fri Oct 31 13:30:19 2008
@@ -850,7 +850,8 @@
while (MBBI != MBB.begin()) {
MachineBasicBlock::iterator PI = prior(MBBI);
unsigned Opc = PI->getOpcode();
- if (Opc != X86::POP32r && Opc != X86::POP64r && !PI->getDesc().isReturn())
+ if (Opc != X86::POP32r && Opc != X86::POP64r &&
+ !PI->getDesc().isTerminator())
break;
--MBBI;
}
More information about the llvm-commits
mailing list