From: Chris Lattner Date: Tue, 16 May 2006 17:08:35 +0000 (+0000) Subject: Fix a bug I introduced yesterday, which broke functions with *no* arguments. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=e7746c9084bbd04a37a38571bfc289b40b71cc63;p=oota-llvm.git Fix a bug I introduced yesterday, which broke functions with *no* arguments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28326 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/X86/X86ISelLowering.cpp b/lib/Target/X86/X86ISelLowering.cpp index 3c4dd2b60ec..1971adae737 100644 --- a/lib/Target/X86/X86ISelLowering.cpp +++ b/lib/Target/X86/X86ISelLowering.cpp @@ -542,6 +542,9 @@ void X86TargetLowering::LowerCCCArguments(SDOperand Op, SelectionDAG &DAG) { } FormalArgs.push_back(ArgValue); } + // Provide a chain. Note that this isn't the right one, but it works as well + // as before. + FormalArgs.push_back(DAG.getEntryNode()); } std::pair @@ -1081,6 +1084,10 @@ X86TargetLowering::LowerFastCCArguments(SDOperand Op, SelectionDAG &DAG) { } FormalArgs.push_back(ArgValue); } + + // Provide a chain. Note that this isn't the right one, but it works as well + // as before. + FormalArgs.push_back(DAG.getEntryNode()); } std::pair