mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-19 19:52:00 +00:00
Explicitly check for StoreInst, do not lose the chance to delete
unused loads or bitcasts. llvm-svn: 67202
This commit is contained in:
parent
fd26fc58bd
commit
4e5f2198ff
@ -1223,7 +1223,7 @@ void SROA::CleanupAllocaUsers(AllocationInst *AI) {
|
||||
CleanupGEP(GEPI);
|
||||
else if (Instruction *I = dyn_cast<Instruction>(U)) {
|
||||
SmallVector<DbgInfoIntrinsic *, 2> DbgInUses;
|
||||
if (!I->use_empty() && OnlyUsedByDbgInfoIntrinsics(I, &DbgInUses)) {
|
||||
if (!isa<StoreInst>(I) && OnlyUsedByDbgInfoIntrinsics(I, &DbgInUses)) {
|
||||
// Safe to remove debug info uses.
|
||||
while (!DbgInUses.empty()) {
|
||||
DbgInfoIntrinsic *DI = DbgInUses.back(); DbgInUses.pop_back();
|
||||
|
Loading…
x
Reference in New Issue
Block a user