aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2007-11-02 17:45:40 +0000
committerEvan Cheng <evan.cheng@apple.com>2007-11-02 17:45:40 +0000
commita9d641e574b350b75d43c7481d6b6c4a7fba1c01 (patch)
tree013112bf781457dfdbaa4472aca0d5053b66d748
parentdeb36bd9d428d6182a7d89fe01bd1b2845645cac (diff)
Unbreak tailcall opt.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43646 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Target/X86/X86ISelLowering.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Target/X86/X86ISelLowering.cpp b/lib/Target/X86/X86ISelLowering.cpp
index 7bd01b09cc..dc9cf99fde 100644
--- a/lib/Target/X86/X86ISelLowering.cpp
+++ b/lib/Target/X86/X86ISelLowering.cpp
@@ -1466,7 +1466,7 @@ bool X86TargetLowering::IsEligibleForTailCallOptimization(SDOperand Call,
if ((NumOps == 1 &&
(Ret.getOperand(0) == SDOperand(Call.Val,1) ||
Ret.getOperand(0) == SDOperand(Call.Val,0))) ||
- (NumOps == 2 &&
+ (NumOps > 1 &&
Ret.getOperand(0) == SDOperand(Call.Val,Call.Val->getNumValues()-1) &&
Ret.getOperand(1) == SDOperand(Call.Val,0))) {
MachineFunction &MF = DAG.getMachineFunction();