[llvm-commits] [llvm] r94625 - /llvm/trunk/lib/Target/X86/X86FastISel.cpp
Evan Cheng
evan.cheng at apple.com
Tue Jan 26 16:00:58 PST 2010
Author: evancheng
Date: Tue Jan 26 18:00:57 2010
New Revision: 94625
URL: http://llvm.org/viewvc/llvm-project?rev=94625&view=rev
Log:
Restore to pre-94570 state.
Modified:
llvm/trunk/lib/Target/X86/X86FastISel.cpp
Modified: llvm/trunk/lib/Target/X86/X86FastISel.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86FastISel.cpp?rev=94625&r1=94624&r2=94625&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86FastISel.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86FastISel.cpp Tue Jan 26 18:00:57 2010
@@ -31,6 +31,7 @@
#include "llvm/Support/CallSite.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/GetElementPtrTypeIterator.h"
+#include "llvm/Target/TargetOptions.h"
using namespace llvm;
namespace {
@@ -1243,6 +1244,11 @@
CC != CallingConv::X86_FastCall)
return false;
+ // fastcc with -tailcallopt is intended to provide a guaranteed
+ // tail call optimization. Fastisel doesn't know how to do that.
+ if (CC == CallingConv::Fast && PerformTailCallOpt)
+ return false;
+
// Let SDISel handle vararg functions.
const PointerType *PT = cast<PointerType>(CS.getCalledValue()->getType());
const FunctionType *FTy = cast<FunctionType>(PT->getElementType());
More information about the llvm-commits
mailing list