[llvm-commits] CVS: llvm/lib/Target/X86/X86ISelLowering.cpp

Chris Lattner lattner at cs.uiuc.edu
Mon Dec 26 19:02:30 PST 2005



Changes in directory llvm/lib/Target/X86:

X86ISelLowering.cpp updated: 1.17 -> 1.18
---
Log message:

Fix a problem duraid pointed out to me compiling kc++ with -enable-x86-fastcc


---
Diffs of the changes:  (+5 -0)

 X86ISelLowering.cpp |    5 +++++
 1 files changed, 5 insertions(+)


Index: llvm/lib/Target/X86/X86ISelLowering.cpp
diff -u llvm/lib/Target/X86/X86ISelLowering.cpp:1.17 llvm/lib/Target/X86/X86ISelLowering.cpp:1.18
--- llvm/lib/Target/X86/X86ISelLowering.cpp:1.17	Fri Dec 23 01:31:11 2005
+++ llvm/lib/Target/X86/X86ISelLowering.cpp	Mon Dec 26 21:02:18 2005
@@ -591,6 +591,9 @@
                                     X86::R8RegisterClass);
           ArgValue = DAG.getCopyFromReg(DAG.getRoot(), VReg, MVT::i8);
           DAG.setRoot(ArgValue.getValue(1));
+          if (ObjectVT == MVT::i1)
+            // FIXME: Should insert a assertzext here.
+            ArgValue = DAG.getNode(ISD::TRUNCATE, MVT::i1, ArgValue);
         }
         ++NumIntRegs;
         break;
@@ -780,6 +783,8 @@
     switch (getValueType(Args[i].second)) {
     default: assert(0 && "Unexpected ValueType for argument!");
     case MVT::i1:
+      Args[i].first = DAG.getNode(ISD::ANY_EXTEND, MVT::i8, Args[i].first);
+      // Fall through.
     case MVT::i8:
     case MVT::i16:
     case MVT::i32:






More information about the llvm-commits mailing list