This code was dead because we AI->replaceUsesWithIf above. I verified
this doesn't actually get run by applying
https://gist.github.com/fmayer/
aea7cbb4700cfe2c9d932591ae1073c3 to the
Android toolchain and building AOSP, without any crash.
Reviewed By: eugenis
Differential Revision: https://reviews.llvm.org/D119802
II->eraseFromParent();
}
}
- if (memtag::alignAndPadAlloca(Info, Align(Mapping.getObjectAlignment()))) {
- for (auto DVI : Info.DbgVariableIntrinsics) {
- SmallDenseSet<Value *> LocationOps(DVI->location_ops().begin(),
- DVI->location_ops().end());
- for (Value *V : LocationOps) {
- if (auto *AI = dyn_cast_or_null<AllocaInst>(V)) {
- if (V == AI)
- DVI->replaceVariableLocationOp(V, Info.AI);
- }
- }
- }
+ if (memtag::alignAndPadAlloca(Info, Align(Mapping.getObjectAlignment())))
AI->eraseFromParent();
- }
}
for (auto &I : SInfo.UnrecognizedLifetimes)
I->eraseFromParent();