diff options
Diffstat (limited to 'llvm/lib/Transforms/Utils/LoopRotationUtils.cpp')
-rw-r--r-- | llvm/lib/Transforms/Utils/LoopRotationUtils.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Transforms/Utils/LoopRotationUtils.cpp b/llvm/lib/Transforms/Utils/LoopRotationUtils.cpp index 0f58f18bc87..514c594ddfa 100644 --- a/llvm/lib/Transforms/Utils/LoopRotationUtils.cpp +++ b/llvm/lib/Transforms/Utils/LoopRotationUtils.cpp @@ -304,13 +304,13 @@ bool LoopRotate::rotateLoop(Loop *L, bool SimplifiedLatch) { // Record all debug intrinsics preceding LoopEntryBranch to avoid duplication. using DbgIntrinsicHash = std::pair<std::pair<Value *, DILocalVariable *>, DIExpression *>; - auto makeHash = [](DbgInfoIntrinsic *D) -> DbgIntrinsicHash { + auto makeHash = [](DbgVariableIntrinsic *D) -> DbgIntrinsicHash { return {{D->getVariableLocation(), D->getVariable()}, D->getExpression()}; }; SmallDenseSet<DbgIntrinsicHash, 8> DbgIntrinsics; for (auto I = std::next(OrigPreheader->rbegin()), E = OrigPreheader->rend(); I != E; ++I) { - if (auto *DII = dyn_cast<DbgInfoIntrinsic>(&*I)) + if (auto *DII = dyn_cast<DbgVariableIntrinsic>(&*I)) DbgIntrinsics.insert(makeHash(DII)); else break; @@ -340,7 +340,7 @@ bool LoopRotate::rotateLoop(Loop *L, bool SimplifiedLatch) { RF_NoModuleLevelChanges | RF_IgnoreMissingLocals); // Avoid inserting the same intrinsic twice. - if (auto *DII = dyn_cast<DbgInfoIntrinsic>(C)) + if (auto *DII = dyn_cast<DbgVariableIntrinsic>(C)) if (DbgIntrinsics.count(makeHash(DII))) { C->deleteValue(); continue; |