[llvm] [NFC] Use more efficient data structures in SubtargetEmitter (PR #102090)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 6 08:15:09 PDT 2024
================
@@ -260,7 +260,7 @@ unsigned SubtargetEmitter::FeatureKeyValues(
llvm::sort(FeatureList, LessRecordFieldName());
// Check that there are no duplicate keys
- std::set<StringRef> UniqueKeys;
+ llvm::StringSet<> UniqueKeys;
----------------
nikic wrote:
This should use `DenseSet<StringRef>`, not `StringSet`. Only use StringSet if the set must own the strings.
https://github.com/llvm/llvm-project/pull/102090
More information about the llvm-commits
mailing list