llvm.org GIT mirror llvm / 7bbe219
[llvm-exegesis] Don't default to running&dumping all analyses to '-' Summary: Up until the point i have looked in the source, i didn't even understood that i can disable 'cluster' output. I have always silenced it via ` &> /dev/null`. (And hoped it wasn't contributing much of the run time.) While i expect that it has it's use-cases i never once needed it so far. If i forget to silence it, console is completely flooded with that output. How about not expecting users to opt-out of analyses, but to explicitly specify the analyses that should be performed? Reviewers: courbet, gchatelet Reviewed By: courbet Subscribers: tschuett, RKSimon, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D57648 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@353021 91177308-0d34-0410-b5e6-96231b3b80d8 Roman Lebedev 1 year, 9 months ago
5 changed file(s) with 17 addition(s) and 8 deletion(s). Raw diff Collapse all Expand all
189189
190190 .. option:: -mode=[latency|uops|inverse_throughput|analysis]
191191
192 Specify the run mode.
192 Specify the run mode. Note that if you pick `analysis` mode, you also need
193 to specify at least one of the `-analysis-clusters-output-file=` and
194 `-analysis-inconsistencies-output-file=`.
193195
194196 .. option:: -num-repetitions=
195197
204206 .. option:: -analysis-clusters-output-file=
205207
206208 If provided, write the analysis clusters as CSV to this file. "-" prints to
207 stdout.
209 stdout. By default, this analysis is not run.
208210
209211 .. option:: -analysis-inconsistencies-output-file=
210212
211213 If non-empty, write inconsistencies found during analysis to this file. `-`
212 prints to stdout.
214 prints to stdout. By default, this analysis is not run.
213215
214216 .. option:: -analysis-numpoints=
215217
0 # This tests backwards-compatibility of the yaml schema (see PR39082).
1 # RUN: llvm-exegesis -mode=analysis -benchmarks-file=%s -analysis-inconsistencies-output-file="" -analysis-numpoints=1 | FileCheck %s
1 # RUN: llvm-exegesis -mode=analysis -benchmarks-file=%s -analysis-clusters-output-file=- -analysis-numpoints=1 | FileCheck %s
22
33 # CHECK: cluster_id,opcode_name,config,sched_class,HWPort0,HWPort1,HWPort2,HWPort3,HWPort4,HWPort5,HWPort6,HWPort7,NumMicroOps
44 # CHECK-NEXT: vzeroall
None # RUN: llvm-exegesis -mode=analysis -benchmarks-file=%s -analysis-inconsistencies-output-file="" -analysis-numpoints=1 | FileCheck %s
0 # RUN: llvm-exegesis -mode=analysis -benchmarks-file=%s -analysis-clusters-output-file=- -analysis-numpoints=1 | FileCheck %s
11
22 # REQUIRES: asserts
33 # (sched class name is NDEBUG only)
None # RUN: llvm-exegesis -mode=analysis -benchmarks-file=%s -analysis-inconsistencies-output-file="" -analysis-numpoints=1 | FileCheck %s
0 # RUN: llvm-exegesis -mode=analysis -benchmarks-file=%s -analysis-clusters-output-file=- -analysis-numpoints=1 | FileCheck %s
11
22 # CHECK: cluster_id,opcode_name,config,sched_class,HWPort0,HWPort1,HWPort2,HWPort3,HWPort4,HWPort5,HWPort6,HWPort7,NumMicroOps
33 # CHECK-NEXT: vzeroall
9090
9191 static cl::opt
9292 AnalysisClustersOutputFile("analysis-clusters-output-file", cl::desc(""),
93 cl::init("-"));
93 cl::init(""));
9494 static cl::opt
9595 AnalysisInconsistenciesOutputFile("analysis-inconsistencies-output-file",
96 cl::desc(""), cl::init("-"));
96 cl::desc(""), cl::init(""));
9797
9898 static cl::opt
9999 CpuName("mcpu",
403403 if (BenchmarkFile.empty())
404404 llvm::report_fatal_error("--benchmarks-file must be set.");
405405
406 if (AnalysisClustersOutputFile.empty() &&
407 AnalysisInconsistenciesOutputFile.empty()) {
408 llvm::report_fatal_error(
409 "At least one of --analysis-clusters-output-file and "
410 "--analysis-inconsistencies-output-file must be specified.");
411 }
412
406413 llvm::InitializeNativeTarget();
407414 llvm::InitializeNativeTargetAsmPrinter();
408415 llvm::InitializeNativeTargetDisassembler();