Skip to content

Commit 3af87a0

Browse files
committed
[llvm-exegesis][AArch64] Revert back unnecessary unfolded error and formatting changes.
1 parent 06fbe30 commit 3af87a0

File tree

1 file changed

+10
-16
lines changed

1 file changed

+10
-16
lines changed

llvm/tools/llvm-exegesis/lib/Target.cpp

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -39,18 +39,12 @@ const char *
3939
ExegesisTarget::getIgnoredOpcodeReasonOrNull(const LLVMState &State,
4040
unsigned Opcode) const {
4141
const MCInstrDesc &InstrDesc = State.getIC().getInstr(Opcode).Description;
42-
if (InstrDesc.isPseudo())
43-
return "Unsupported opcode: isPseudo";
44-
if (InstrDesc.usesCustomInsertionHook())
45-
return "Unsupported opcode: usesCustomInserter";
46-
if (InstrDesc.isBranch())
47-
return "Unsupported opcode: isBranch";
48-
if (InstrDesc.isIndirectBranch())
49-
return "Unsupported opcode: isIndirectBranch";
50-
if (InstrDesc.isCall())
51-
return "Unsupported opcode: isCall";
52-
if (InstrDesc.isReturn())
53-
return "Unsupported opcode: isReturn";
42+
if (InstrDesc.isPseudo() || InstrDesc.usesCustomInsertionHook())
43+
return "Unsupported opcode: isPseudo/usesCustomInserter";
44+
if (InstrDesc.isBranch() || InstrDesc.isIndirectBranch())
45+
return "Unsupported opcode: isBranch/isIndirectBranch";
46+
if (InstrDesc.isCall() || InstrDesc.isReturn())
47+
return "Unsupported opcode: isCall/isReturn";
5448
return nullptr;
5549
}
5650

@@ -119,8 +113,9 @@ ExegesisTarget::createBenchmarkRunner(
119113
case Benchmark::InverseThroughput:
120114
if (BenchmarkPhaseSelector == BenchmarkPhaseSelectorE::Measure &&
121115
!PfmCounters.CycleCounter) {
122-
const char *ModeName =
123-
Mode == Benchmark::Latency ? "latency" : "inverse_throughput";
116+
const char *ModeName = Mode == Benchmark::Latency
117+
? "latency"
118+
: "inverse_throughput";
124119
return make_error<Failure>(
125120
Twine("can't run '")
126121
.concat(ModeName)
@@ -153,8 +148,7 @@ std::unique_ptr<SnippetGenerator> ExegesisTarget::createSerialSnippetGenerator(
153148
return std::make_unique<SerialSnippetGenerator>(State, Opts);
154149
}
155150

156-
std::unique_ptr<SnippetGenerator>
157-
ExegesisTarget::createParallelSnippetGenerator(
151+
std::unique_ptr<SnippetGenerator> ExegesisTarget::createParallelSnippetGenerator(
158152
const LLVMState &State, const SnippetGenerator::Options &Opts) const {
159153
return std::make_unique<ParallelSnippetGenerator>(State, Opts);
160154
}

0 commit comments

Comments
 (0)