aboutsummaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-exegesis/lib/BenchmarkResult.cpp
diff options
context:
space:
mode:
authorRoman Lebedev <lebedev.ri@gmail.com>2022-12-17 16:48:07 +0300
committerRoman Lebedev <lebedev.ri@gmail.com>2022-12-17 17:10:48 +0300
commit5b1592b5c50e71d54382a400264f3539a4aad9a1 (patch)
tree550da4903763b8663daf5304098fa245316fda43 /llvm/tools/llvm-exegesis/lib/BenchmarkResult.cpp
parent2ee17d691f4f34769b64fffc6fe704ae13667256 (diff)
downloadllvm-5b1592b5c50e71d54382a400264f3539a4aad9a1.zip
llvm-5b1592b5c50e71d54382a400264f3539a4aad9a1.tar.gz
llvm-5b1592b5c50e71d54382a400264f3539a4aad9a1.tar.bz2
[NFC][llvm-exegesis] LLVMState: only store references to reg/op names
We know that the original reference from which we've built these maps will persist, so we do not need to copy the names.
Diffstat (limited to 'llvm/tools/llvm-exegesis/lib/BenchmarkResult.cpp')
-rw-r--r--llvm/tools/llvm-exegesis/lib/BenchmarkResult.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/tools/llvm-exegesis/lib/BenchmarkResult.cpp b/llvm/tools/llvm-exegesis/lib/BenchmarkResult.cpp
index 3972bb3..593b41e 100644
--- a/llvm/tools/llvm-exegesis/lib/BenchmarkResult.cpp
+++ b/llvm/tools/llvm-exegesis/lib/BenchmarkResult.cpp
@@ -152,8 +152,8 @@ private:
const exegesis::LLVMState *State;
std::string LastError;
raw_string_ostream ErrorStream;
- const StringMap<unsigned> &OpcodeNameToOpcodeIdx;
- const StringMap<unsigned> &RegNameToRegNo;
+ const DenseMap<StringRef, unsigned> &OpcodeNameToOpcodeIdx;
+ const DenseMap<StringRef, unsigned> &RegNameToRegNo;
};
} // namespace