Mesa (main): aco/spill: Replace map[] with map::insert
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Fri Oct 1 09:57:11 UTC 2021
Module: Mesa
Branch: main
Commit: 276da301e6803023560164679c48fc0e07f2b8d2
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=276da301e6803023560164679c48fc0e07f2b8d2
Author: Tony Wasserka <tony.wasserka at gmx.de>
Date: Thu Jul 15 16:13:58 2021 +0200
aco/spill: Replace map[] with map::insert
Reviewed-by: Daniel Schürmann <daniel at schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11925>
---
src/amd/compiler/aco_spill.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/amd/compiler/aco_spill.cpp b/src/amd/compiler/aco_spill.cpp
index 499512150f3..646b492fbc9 100644
--- a/src/amd/compiler/aco_spill.cpp
+++ b/src/amd/compiler/aco_spill.cpp
@@ -362,7 +362,7 @@ local_next_uses(spill_ctx& ctx, Block* block)
std::map<Temp, uint32_t> next_uses;
for (std::pair<const Temp, std::pair<uint32_t, uint32_t>>& pair :
ctx.next_use_distances_end[block->index])
- next_uses[pair.first] = pair.second.second + block->instructions.size();
+ next_uses.insert({pair.first, pair.second.second + block->instructions.size()});
for (int idx = block->instructions.size() - 1; idx >= 0; idx--) {
aco_ptr<Instruction>& instr = block->instructions[idx];
More information about the mesa-commit
mailing list