Index: test/tools/llvm-exegesis/X86/latency-by-opcode-name.s =================================================================== --- test/tools/llvm-exegesis/X86/latency-by-opcode-name.s +++ test/tools/llvm-exegesis/X86/latency-by-opcode-name.s @@ -1,6 +1,8 @@ # RUN: llvm-exegesis -mode=latency -opcode-name=ADD32rr | FileCheck %s -CHECK: mode: latency +CHECK: --- +CHECK-NEXT: mode: latency CHECK-NEXT: key: CHECK-NEXT: instructions: CHECK-NEXT: ADD32rr +CHECK-LAST: ... Index: tools/llvm-exegesis/lib/BenchmarkResult.cpp =================================================================== --- tools/llvm-exegesis/lib/BenchmarkResult.cpp +++ tools/llvm-exegesis/lib/BenchmarkResult.cpp @@ -269,7 +269,9 @@ llvm::raw_ostream &OS) { llvm::yaml::Output Yout(OS); YamlContext Context(State); + Yout.beginDocuments(); llvm::yaml::yamlize(Yout, *this, /*unused*/ true, Context); + Yout.endDocuments(); } void InstructionBenchmark::readYamlFrom(const LLVMState &State,