forked from OSchip/llvm-project
BlockGenerator: Assert that we do not get alloca of array access
llvm-svn: 277698
This commit is contained in:
parent
576932728d
commit
3216f8546c
|
@ -363,6 +363,8 @@ Value *BlockGenerator::getOrCreateAlloca(Value *ScalarBase,
|
|||
}
|
||||
|
||||
Value *BlockGenerator::getOrCreateAlloca(const MemoryAccess &Access) {
|
||||
assert(!Access.isArrayKind() && "Trying to get alloca for array kind");
|
||||
|
||||
if (Access.isPHIKind())
|
||||
return getOrCreatePHIAlloca(Access.getBaseAddr());
|
||||
else
|
||||
|
@ -370,6 +372,8 @@ Value *BlockGenerator::getOrCreateAlloca(const MemoryAccess &Access) {
|
|||
}
|
||||
|
||||
Value *BlockGenerator::getOrCreateAlloca(const ScopArrayInfo *Array) {
|
||||
assert(!Array->isArrayKind() && "Trying to get alloca for array kind");
|
||||
|
||||
if (Array->isPHIKind())
|
||||
return getOrCreatePHIAlloca(Array->getBasePtr());
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue