reland r332579: [llvm-exegesis] Update to cover latency through another opcode.
Restructuring the code to measure latency and uops.
The end goal is to have this program spawn another process to deal with SIGILL and other malformed programs. It is not yet the case in this redesign, it is still the main program that runs the code (and may crash).
It now uses BitVector instead of Graph for performance reasons.
https://reviews.llvm.org/D46821
(with fixed ARM tests)
Authored by Guillaume Chatelet
llvm-svn: 332592
diff --git a/llvm/tools/llvm-exegesis/lib/BenchmarkResult.h b/llvm/tools/llvm-exegesis/lib/BenchmarkResult.h
index cf9bcec..3a7d241 100644
--- a/llvm/tools/llvm-exegesis/lib/BenchmarkResult.h
+++ b/llvm/tools/llvm-exegesis/lib/BenchmarkResult.h
@@ -50,9 +50,14 @@
std::string Info;
static InstructionBenchmark readYamlOrDie(llvm::StringRef Filename);
- static std::vector<InstructionBenchmark> readYamlsOrDie(llvm::StringRef Filename);
+ static std::vector<InstructionBenchmark>
- // Unfortunately this function is non const because of YAML traits.
+ // Read functions.
+ readYamlsOrDie(llvm::StringRef Filename);
+ void readYamlFrom(llvm::StringRef InputContent);
+
+ // Write functions, non-const because of YAML traits.
+ void writeYamlTo(llvm::raw_ostream &S);
void writeYamlOrDie(const llvm::StringRef Filename);
};