-
Notifications
You must be signed in to change notification settings - Fork 14.3k
[CodeGen] Avoid repeated hash lookups (NFC) #124455
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[CodeGen] Avoid repeated hash lookups (NFC) #124455
Conversation
@llvm/pr-subscribers-llvm-regalloc Author: Kazu Hirata (kazutakahirata) ChangesFull diff: https://github.com/llvm/llvm-project/pull/124455.diff 1 Files Affected:
diff --git a/llvm/lib/CodeGen/InlineSpiller.cpp b/llvm/lib/CodeGen/InlineSpiller.cpp
index d98254650a001c..33915d0f7f8297 100644
--- a/llvm/lib/CodeGen/InlineSpiller.cpp
+++ b/llvm/lib/CodeGen/InlineSpiller.cpp
@@ -1578,7 +1578,8 @@ void HoistSpillHelper::runHoistSpills(
for (auto *const SpillBB : SpillsInSubTree) {
// When SpillBB is a BB contains original spill, insert the spill
// to SpillsToRm.
- if (SpillsToKeep.contains(SpillBB) && !SpillsToKeep[SpillBB]) {
+ if (auto It = SpillsToKeep.find(SpillBB);
+ It != SpillsToKeep.end() && !It->second) {
MachineInstr *SpillToRm = SpillBBToSpill[SpillBB];
SpillsToRm.push_back(SpillToRm);
}
|
LLVM Buildbot has detected a new failure on builder Full details are available at: https://lab.llvm.org/buildbot/#/builders/73/builds/12442 Here is the relevant piece of the build log for the reference
|
No description provided.