Fix build with LLVM 2.9.

This commit is contained in:
Matt Pharr
2012-04-05 08:22:40 -07:00
parent 1dac05960a
commit 4c9ac7fcf1
2 changed files with 12 additions and 1 deletions

View File

@@ -1443,7 +1443,10 @@ lExtractFirstVectorElement(llvm::Value *v, llvm::Instruction *insertBefore,
llvm::Instruction *phiInsertPos = phi->getParent()->begin();
llvm::PHINode *scalarPhi =
llvm::PHINode::Create(vt->getElementType(),
phi->getNumIncomingValues(), newName,
#ifndef LLVM_2_9
phi->getNumIncomingValues(),
#endif // !LLVM_2_9
newName,
phiInsertPos);
phiMap[phi] = scalarPhi;