Skip to content

Commit 8944c57

Browse files
kazutakahiratagithub-actions[bot]
authored andcommitted
Automerge: [Hexagon] Avoid repeated map lookups (NFC) (#125815)
2 parents 0250e15 + e9dd4a8 commit 8944c57

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

llvm/lib/Target/Hexagon/HexagonISelDAGToDAGHVX.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,8 +262,7 @@ bool Coloring::color() {
262262

263263
// Explicitly assign "None" to all uncolored nodes.
264264
for (unsigned I = 0; I != Order.size(); ++I)
265-
if (Colors.count(I) == 0)
266-
Colors[I] = ColorKind::None;
265+
Colors.try_emplace(I, ColorKind::None);
267266

268267
return true;
269268
}

0 commit comments

Comments
 (0)