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

Tanya Lattner tonic at nondot.org
Thu Nov 9 20:28:48 PST 2006



Changes in directory llvm/lib/Target/X86:

X86ISelLowering.cpp updated: 1.287.2.2 -> 1.287.2.3
---
Log message:

Merging from mainline


---
Diffs of the changes:  (+6 -6)

 X86ISelLowering.cpp |   12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)


Index: llvm/lib/Target/X86/X86ISelLowering.cpp
diff -u llvm/lib/Target/X86/X86ISelLowering.cpp:1.287.2.2 llvm/lib/Target/X86/X86ISelLowering.cpp:1.287.2.3
--- llvm/lib/Target/X86/X86ISelLowering.cpp:1.287.2.2	Thu Nov  9 22:27:20 2006
+++ llvm/lib/Target/X86/X86ISelLowering.cpp	Thu Nov  9 22:28:35 2006
@@ -516,10 +516,9 @@
   BytesToPopOnReturn = 0;         // Callee pops nothing.
   BytesCallerReserves = ArgOffset;
 
-  // If this is a struct return on Darwin/X86, the callee pops the hidden struct
-  // pointer.
-  if (MF.getFunction()->getCallingConv() == CallingConv::CSRet &&
-      Subtarget->isTargetDarwin())
+  // If this is a struct return on, the callee pops the hidden struct
+  // pointer. This is common for Darwin/X86, Linux & Mingw32 targets.
+  if (MF.getFunction()->getCallingConv() == CallingConv::CSRet)
     BytesToPopOnReturn = 4;
 
   // Return the new list of results.
@@ -680,9 +679,10 @@
   // Create the CALLSEQ_END node.
   unsigned NumBytesForCalleeToPush = 0;
 
-  // If this is is a call to a struct-return function on Darwin/X86, the callee
+  // If this is is a call to a struct-return function, the callee
   // pops the hidden struct pointer, so we have to push it back.
-  if (CallingConv == CallingConv::CSRet && Subtarget->isTargetDarwin())
+  // This is common for Darwin/X86, Linux & Mingw32 targets.
+  if (CallingConv == CallingConv::CSRet)
     NumBytesForCalleeToPush = 4;
   
   NodeTys.clear();






More information about the llvm-commits mailing list