projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
abb1b58
)
Reserve space for PHI operands
author
Chris Lattner
<sabre@nondot.org>
Fri, 10 Oct 2003 16:34:58 +0000
(16:34 +0000)
committer
Chris Lattner
<sabre@nondot.org>
Fri, 10 Oct 2003 16:34:58 +0000
(16:34 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9007
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/AsmParser/llvmAsmParser.y
patch
|
blob
|
history
diff --git
a/lib/AsmParser/llvmAsmParser.y
b/lib/AsmParser/llvmAsmParser.y
index dcfb94365733a1436daac82715e574ce21042761..f9c076c7ea5ed5591167206ae6c71cabe92c1ca8 100644
(file)
--- a/
lib/AsmParser/llvmAsmParser.y
+++ b/
lib/AsmParser/llvmAsmParser.y
@@
-1649,6
+1649,7
@@
InstVal : ArithmeticOps Types ValueRef ',' ValueRef {
| PHI PHIList {
const Type *Ty = $2->front().first->getType();
$$ = new PHINode(Ty);
+ $$->op_reserve($2->size()*2);
while ($2->begin() != $2->end()) {
if ($2->front().first->getType() != Ty)
ThrowException("All elements of a PHI node must be of the same type!");