[NFC][llvm-exegesis] Ensure that target options show up in --help

Fixes https://github.com/llvm/llvm-project/issues/59377
This commit is contained in:
Roman Lebedev 2022-12-21 03:38:10 +03:00
parent 8fd62e70cd
commit 03aa6b9197
No known key found for this signature in database
GPG Key ID: 083C3EBB4A1689E0
4 changed files with 9 additions and 7 deletions

View File

@ -17,6 +17,10 @@
namespace llvm {
namespace exegesis {
cl::OptionCategory Options("llvm-exegesis options");
cl::OptionCategory BenchmarkOptions("llvm-exegesis benchmark options");
cl::OptionCategory AnalysisOptions("llvm-exegesis analysis options");
ExegesisTarget::~ExegesisTarget() {} // anchor.
static ExegesisTarget *FirstTarget = nullptr;

View File

@ -28,11 +28,16 @@
#include "llvm/IR/LegacyPassManager.h"
#include "llvm/MC/MCInst.h"
#include "llvm/MC/MCRegisterInfo.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Error.h"
namespace llvm {
namespace exegesis {
extern cl::OptionCategory Options;
extern cl::OptionCategory BenchmarkOptions;
extern cl::OptionCategory AnalysisOptions;
struct PfmCountersInfo {
// An optional name of a performance counter that can be used to measure
// cycles.

View File

@ -38,9 +38,6 @@
namespace llvm {
namespace exegesis {
static cl::OptionCategory
BenchmarkOptions("llvm-exegesis benchmark x86-options");
// If a positive value is specified, we are going to use the LBR in
// latency-mode.
//

View File

@ -47,10 +47,6 @@
namespace llvm {
namespace exegesis {
static cl::OptionCategory Options("llvm-exegesis options");
static cl::OptionCategory BenchmarkOptions("llvm-exegesis benchmark options");
static cl::OptionCategory AnalysisOptions("llvm-exegesis analysis options");
static cl::opt<int> OpcodeIndex(
"opcode-index",
cl::desc("opcode to measure, by index, or -1 to measure all opcodes"),