Fix bug in previous checkin
authorChris Lattner <sabre@nondot.org>
Fri, 11 Jun 2004 05:22:44 +0000 (05:22 +0000)
committerChris Lattner <sabre@nondot.org>
Fri, 11 Jun 2004 05:22:44 +0000 (05:22 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14146 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/X86/FloatingPoint.cpp
lib/Target/X86/X86FloatingPoint.cpp

index ab6d77b77dde40fbdbae13871e753a946e3b20a1..a56e071cf1457fcc79880b25f1fe3ec81a5092d3 100644 (file)
@@ -638,6 +638,9 @@ void FPS::handleCompareFP(MachineBasicBlock::iterator &I) {
   // anywhere.
   moveToTop(Op0, I);
 
+  MI->getOperand(0).setReg(getSTReg(Op1));
+  MI->RemoveOperand(1);
+
   // If any of the operands are killed by this instruction, free them.
   if (KillsOp0) freeStackSlotAfter(I, Op0);
   if (KillsOp1 && Op0 != Op1) freeStackSlotAfter(I, Op1);
index ab6d77b77dde40fbdbae13871e753a946e3b20a1..a56e071cf1457fcc79880b25f1fe3ec81a5092d3 100644 (file)
@@ -638,6 +638,9 @@ void FPS::handleCompareFP(MachineBasicBlock::iterator &I) {
   // anywhere.
   moveToTop(Op0, I);
 
+  MI->getOperand(0).setReg(getSTReg(Op1));
+  MI->RemoveOperand(1);
+
   // If any of the operands are killed by this instruction, free them.
   if (KillsOp0) freeStackSlotAfter(I, Op0);
   if (KillsOp1 && Op0 != Op1) freeStackSlotAfter(I, Op1);