[llvm] [llvm-exegesis] Simplify validation event string conversion functions (PR #82092)
Clement Courbet via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 19 07:25:56 PST 2024
================
@@ -24,6 +24,24 @@ static constexpr const char kIntegerPrefix[] = "i_0x";
static constexpr const char kDoublePrefix[] = "f_";
static constexpr const char kInvalidOperand[] = "INVALID";
+// When adding a new validation counter, a new event type needs to be added
+// to llvm::exegesis::ValidationEvent, a mapping needs to be added below,
+// a command line option needs to be added in llvm-exegesis.cpp, and the
+// event type needs to be added (with matching naming) in TargetPfmCounters.td
+// and appropriate mappings need to be added in the relevant architecture
+// Pfm descriptions.
+static constexpr const std::pair<llvm::exegesis::ValidationEvent,
+ llvm::StringRef>
+ kValidationEventNames[] = {
+ {llvm::exegesis::InstructionRetired, "instructions-retired"},
----------------
legrosbuffle wrote:
I have a proposal in #82256
https://github.com/llvm/llvm-project/pull/82092
More information about the llvm-commits
mailing list