[llvm] [Analysis] Avoid repeated hash lookups (NFC) (PR #127955)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 19 21:19:04 PST 2025
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-llvm-analysis
Author: Kazu Hirata (kazutakahirata)
<details>
<summary>Changes</summary>
---
Full diff: https://github.com/llvm/llvm-project/pull/127955.diff
1 Files Affected:
- (modified) llvm/lib/Analysis/LoopAccessAnalysis.cpp (+1-1)
``````````diff
diff --git a/llvm/lib/Analysis/LoopAccessAnalysis.cpp b/llvm/lib/Analysis/LoopAccessAnalysis.cpp
index 5dc5b025599b1..a2bbe6fb11c09 100644
--- a/llvm/lib/Analysis/LoopAccessAnalysis.cpp
+++ b/llvm/lib/Analysis/LoopAccessAnalysis.cpp
@@ -1431,8 +1431,8 @@ void AccessAnalysis::processMemAccesses() {
typedef SmallVector<const Value *, 16> ValueVector;
ValueVector TempObjects;
- UnderlyingObjects[Ptr] = {};
SmallVector<const Value *, 16> &UOs = UnderlyingObjects[Ptr];
+ UOs = {};
::getUnderlyingObjects(Ptr, UOs, LI);
LLVM_DEBUG(dbgs()
<< "Underlying objects for pointer " << *Ptr << "\n");
``````````
</details>
https://github.com/llvm/llvm-project/pull/127955
More information about the llvm-commits
mailing list