mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-23 01:24:30 +00:00
Look through addrspacecast in GetPointerBaseWithConstantOffset
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@212999 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -1731,7 +1731,8 @@ Value *llvm::GetPointerBaseWithConstantOffset(Value *Ptr, int64_t &Offset,
|
||||
}
|
||||
|
||||
Ptr = GEP->getPointerOperand();
|
||||
} else if (Operator::getOpcode(Ptr) == Instruction::BitCast) {
|
||||
} else if (Operator::getOpcode(Ptr) == Instruction::BitCast ||
|
||||
Operator::getOpcode(Ptr) == Instruction::AddrSpaceCast) {
|
||||
Ptr = cast<Operator>(Ptr)->getOperand(0);
|
||||
} else if (GlobalAlias *GA = dyn_cast<GlobalAlias>(Ptr)) {
|
||||
if (GA->mayBeOverridden())
|
||||
|
Reference in New Issue
Block a user