NULL loads are only invalid in the default address space.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111972 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Owen Anderson 2010-08-24 22:00:55 +00:00
parent dae90c6afb
commit 7bef92ac7a

View File

@ -460,7 +460,7 @@ LVILatticeVal LVIQuery::getBlockValue(BasicBlock *BB) {
for (Value::use_iterator UI = Val->use_begin(), UE = Val->use_end();
UI != UE; ++UI) {
LoadInst *L = dyn_cast<LoadInst>(*UI);
if (L && L->getParent() == BB) {
if (L && L->getParent() == BB && L->getPointerAddressSpace() == 0) {
return LVILatticeVal::getNot(ConstantPointerNull::get(PTy));
}
}