mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-22 02:33:06 +01:00
[llvm][tools] Hide remaining unrelated llvm- tool options
Differential Revision: https://reviews.llvm.org/D106430
This commit is contained in:
parent
c6d5dd6f53
commit
da198e839e
7
test/tools/llvm-reduce/help.test
Normal file
7
test/tools/llvm-reduce/help.test
Normal file
@ -0,0 +1,7 @@
|
||||
# RUN: llvm-reduce --help | FileCheck %s --check-prefix HELP --implicit-check-not='{{[Oo]}}ptions:'
|
||||
|
||||
# HELP: OVERVIEW: LLVM automatic testcase reducer.
|
||||
# HELP: USAGE
|
||||
# HELP: Color Options
|
||||
# HELP: Generic Options
|
||||
# HELP: llvm-reduce options
|
7
test/tools/llvm-rtdyld/help.test
Normal file
7
test/tools/llvm-rtdyld/help.test
Normal file
@ -0,0 +1,7 @@
|
||||
# RUN: llvm-rtdyld --help | FileCheck %s --check-prefix HELP --implicit-check-not='{{[Oo]}}ptions:'
|
||||
|
||||
# HELP: OVERVIEW:
|
||||
# HELP: USAGE
|
||||
# HELP: Color Options
|
||||
# HELP: Generic Options
|
||||
# HELP: RTDyld Options
|
7
test/tools/llvm-split/help.test
Normal file
7
test/tools/llvm-split/help.test
Normal file
@ -0,0 +1,7 @@
|
||||
# RUN: llvm-split --help | FileCheck %s --check-prefix HELP --implicit-check-not='{{[Oo]}}ptions:'
|
||||
|
||||
# HELP: OVERVIEW: LLVM module splitter
|
||||
# HELP: USAGE
|
||||
# HELP: Color Options
|
||||
# HELP: Generic Options
|
||||
# HELP: Split Options
|
7
test/tools/llvm-stress/help.test
Normal file
7
test/tools/llvm-stress/help.test
Normal file
@ -0,0 +1,7 @@
|
||||
# RUN: llvm-stress --help | FileCheck %s --check-prefix HELP --implicit-check-not='{{[Oo]}}ptions:'
|
||||
|
||||
# HELP: OVERVIEW: llvm codegen stress-tester
|
||||
# HELP: USAGE
|
||||
# HELP: Color Options
|
||||
# HELP: Generic Options
|
||||
# HELP: Stress Options
|
6
test/tools/llvm-undname/help.test
Normal file
6
test/tools/llvm-undname/help.test
Normal file
@ -0,0 +1,6 @@
|
||||
# RUN: llvm-undname --help | FileCheck %s --check-prefix HELP --implicit-check-not='{{[Oo]}}ptions:'
|
||||
|
||||
# HELP: OVERVIEW: llvm-undname
|
||||
# HELP: USAGE
|
||||
# HELP: Color Options
|
||||
# HELP: Generic Options
|
@ -105,6 +105,7 @@ void writeOutput(Module *M, StringRef Message) {
|
||||
int main(int Argc, char **Argv) {
|
||||
InitLLVM X(Argc, Argv);
|
||||
|
||||
cl::HideUnrelatedOptions({&Options, &getColorCategory()});
|
||||
cl::ParseCommandLineOptions(Argc, Argv, "LLVM automatic testcase reducer.\n");
|
||||
|
||||
if (PrintDeltaPasses) {
|
||||
|
@ -44,9 +44,11 @@
|
||||
using namespace llvm;
|
||||
using namespace llvm::object;
|
||||
|
||||
static cl::list<std::string>
|
||||
InputFileList(cl::Positional, cl::ZeroOrMore,
|
||||
cl::desc("<input files>"));
|
||||
static cl::OptionCategory RTDyldCategory("RTDyld Options");
|
||||
|
||||
static cl::list<std::string> InputFileList(cl::Positional, cl::ZeroOrMore,
|
||||
cl::desc("<input files>"),
|
||||
cl::cat(RTDyldCategory));
|
||||
|
||||
enum ActionType {
|
||||
AC_Execute,
|
||||
@ -56,94 +58,93 @@ enum ActionType {
|
||||
AC_Verify
|
||||
};
|
||||
|
||||
static cl::opt<ActionType>
|
||||
Action(cl::desc("Action to perform:"),
|
||||
cl::init(AC_Execute),
|
||||
cl::values(clEnumValN(AC_Execute, "execute",
|
||||
"Load, link, and execute the inputs."),
|
||||
clEnumValN(AC_PrintLineInfo, "printline",
|
||||
"Load, link, and print line information for each function."),
|
||||
clEnumValN(AC_PrintDebugLineInfo, "printdebugline",
|
||||
"Load, link, and print line information for each function using the debug object"),
|
||||
clEnumValN(AC_PrintObjectLineInfo, "printobjline",
|
||||
"Like -printlineinfo but does not load the object first"),
|
||||
clEnumValN(AC_Verify, "verify",
|
||||
"Load, link and verify the resulting memory image.")));
|
||||
static cl::opt<ActionType> Action(
|
||||
cl::desc("Action to perform:"), cl::init(AC_Execute),
|
||||
cl::values(
|
||||
clEnumValN(AC_Execute, "execute",
|
||||
"Load, link, and execute the inputs."),
|
||||
clEnumValN(AC_PrintLineInfo, "printline",
|
||||
"Load, link, and print line information for each function."),
|
||||
clEnumValN(AC_PrintDebugLineInfo, "printdebugline",
|
||||
"Load, link, and print line information for each function "
|
||||
"using the debug object"),
|
||||
clEnumValN(AC_PrintObjectLineInfo, "printobjline",
|
||||
"Like -printlineinfo but does not load the object first"),
|
||||
clEnumValN(AC_Verify, "verify",
|
||||
"Load, link and verify the resulting memory image.")),
|
||||
cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::opt<std::string>
|
||||
EntryPoint("entry",
|
||||
cl::desc("Function to call as entry point."),
|
||||
cl::init("_main"));
|
||||
EntryPoint("entry", cl::desc("Function to call as entry point."),
|
||||
cl::init("_main"), cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::list<std::string>
|
||||
Dylibs("dylib",
|
||||
cl::desc("Add library."),
|
||||
cl::ZeroOrMore);
|
||||
static cl::list<std::string> Dylibs("dylib", cl::desc("Add library."),
|
||||
cl::ZeroOrMore, cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::list<std::string> InputArgv("args", cl::Positional,
|
||||
cl::desc("<program arguments>..."),
|
||||
cl::ZeroOrMore, cl::PositionalEatsArgs);
|
||||
cl::ZeroOrMore, cl::PositionalEatsArgs,
|
||||
cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::opt<std::string>
|
||||
TripleName("triple", cl::desc("Target triple for disassembler"));
|
||||
TripleName("triple", cl::desc("Target triple for disassembler"),
|
||||
cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::opt<std::string>
|
||||
MCPU("mcpu",
|
||||
cl::desc("Target a specific cpu type (-mcpu=help for details)"),
|
||||
cl::value_desc("cpu-name"),
|
||||
cl::init(""));
|
||||
MCPU("mcpu",
|
||||
cl::desc("Target a specific cpu type (-mcpu=help for details)"),
|
||||
cl::value_desc("cpu-name"), cl::init(""), cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::list<std::string>
|
||||
CheckFiles("check",
|
||||
cl::desc("File containing RuntimeDyld verifier checks."),
|
||||
cl::ZeroOrMore);
|
||||
CheckFiles("check",
|
||||
cl::desc("File containing RuntimeDyld verifier checks."),
|
||||
cl::ZeroOrMore, cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::opt<uint64_t>
|
||||
PreallocMemory("preallocate",
|
||||
cl::desc("Allocate memory upfront rather than on-demand"),
|
||||
cl::init(0));
|
||||
cl::init(0), cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::opt<uint64_t> TargetAddrStart(
|
||||
"target-addr-start",
|
||||
cl::desc("For -verify only: start of phony target address "
|
||||
"range."),
|
||||
cl::init(4096), // Start at "page 1" - no allocating at "null".
|
||||
cl::Hidden);
|
||||
cl::Hidden, cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::opt<uint64_t> TargetAddrEnd(
|
||||
"target-addr-end",
|
||||
cl::desc("For -verify only: end of phony target address range."),
|
||||
cl::init(~0ULL), cl::Hidden);
|
||||
cl::init(~0ULL), cl::Hidden, cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::opt<uint64_t> TargetSectionSep(
|
||||
"target-section-sep",
|
||||
cl::desc("For -verify only: Separation between sections in "
|
||||
"phony target address space."),
|
||||
cl::init(0), cl::Hidden);
|
||||
cl::init(0), cl::Hidden, cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::list<std::string>
|
||||
SpecificSectionMappings("map-section",
|
||||
cl::desc("For -verify only: Map a section to a "
|
||||
"specific address."),
|
||||
cl::ZeroOrMore,
|
||||
cl::Hidden);
|
||||
SpecificSectionMappings("map-section",
|
||||
cl::desc("For -verify only: Map a section to a "
|
||||
"specific address."),
|
||||
cl::ZeroOrMore, cl::Hidden,
|
||||
cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::list<std::string>
|
||||
DummySymbolMappings("dummy-extern",
|
||||
cl::desc("For -verify only: Inject a symbol into the extern "
|
||||
"symbol table."),
|
||||
cl::ZeroOrMore,
|
||||
cl::Hidden);
|
||||
static cl::list<std::string> DummySymbolMappings(
|
||||
"dummy-extern",
|
||||
cl::desc("For -verify only: Inject a symbol into the extern "
|
||||
"symbol table."),
|
||||
cl::ZeroOrMore, cl::Hidden, cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::opt<bool>
|
||||
PrintAllocationRequests("print-alloc-requests",
|
||||
cl::desc("Print allocation requests made to the memory "
|
||||
"manager by RuntimeDyld"),
|
||||
cl::Hidden);
|
||||
static cl::opt<bool> PrintAllocationRequests(
|
||||
"print-alloc-requests",
|
||||
cl::desc("Print allocation requests made to the memory "
|
||||
"manager by RuntimeDyld"),
|
||||
cl::Hidden, cl::cat(RTDyldCategory));
|
||||
|
||||
static cl::opt<bool> ShowTimes("show-times",
|
||||
cl::desc("Show times for llvm-rtdyld phases"),
|
||||
cl::init(false));
|
||||
cl::init(false), cl::cat(RTDyldCategory));
|
||||
|
||||
ExitOnError ExitOnErr;
|
||||
|
||||
@ -966,6 +967,7 @@ int main(int argc, char **argv) {
|
||||
llvm::InitializeAllTargetMCs();
|
||||
llvm::InitializeAllDisassemblers();
|
||||
|
||||
cl::HideUnrelatedOptions({&RTDyldCategory, &getColorCategory()});
|
||||
cl::ParseCommandLineOptions(argc, argv, "llvm MC-JIT tool\n");
|
||||
|
||||
ExitOnErr.setBanner(std::string(argv[0]) + ": ");
|
||||
|
@ -24,24 +24,32 @@
|
||||
|
||||
using namespace llvm;
|
||||
|
||||
static cl::opt<std::string>
|
||||
InputFilename(cl::Positional, cl::desc("<input bitcode file>"),
|
||||
cl::init("-"), cl::value_desc("filename"));
|
||||
static cl::OptionCategory SplitCategory("Split Options");
|
||||
|
||||
static cl::opt<std::string>
|
||||
OutputFilename("o", cl::desc("Override output filename"),
|
||||
cl::value_desc("filename"));
|
||||
static cl::opt<std::string> InputFilename(cl::Positional,
|
||||
cl::desc("<input bitcode file>"),
|
||||
cl::init("-"),
|
||||
cl::value_desc("filename"),
|
||||
cl::cat(SplitCategory));
|
||||
|
||||
static cl::opt<std::string> OutputFilename("o",
|
||||
cl::desc("Override output filename"),
|
||||
cl::value_desc("filename"),
|
||||
cl::cat(SplitCategory));
|
||||
|
||||
static cl::opt<unsigned> NumOutputs("j", cl::Prefix, cl::init(2),
|
||||
cl::desc("Number of output files"));
|
||||
cl::desc("Number of output files"),
|
||||
cl::cat(SplitCategory));
|
||||
|
||||
static cl::opt<bool>
|
||||
PreserveLocals("preserve-locals", cl::Prefix, cl::init(false),
|
||||
cl::desc("Split without externalizing locals"));
|
||||
cl::desc("Split without externalizing locals"),
|
||||
cl::cat(SplitCategory));
|
||||
|
||||
int main(int argc, char **argv) {
|
||||
LLVMContext Context;
|
||||
SMDiagnostic Err;
|
||||
cl::HideUnrelatedOptions({&SplitCategory, &getColorCategory()});
|
||||
cl::ParseCommandLineOptions(argc, argv, "LLVM module splitter\n");
|
||||
|
||||
std::unique_ptr<Module> M = parseIRFile(InputFilename, Err, Context);
|
||||
|
@ -52,16 +52,20 @@
|
||||
|
||||
namespace llvm {
|
||||
|
||||
static cl::opt<unsigned> SeedCL("seed",
|
||||
cl::desc("Seed used for randomness"), cl::init(0));
|
||||
static cl::OptionCategory StressCategory("Stress Options");
|
||||
|
||||
static cl::opt<unsigned> SizeCL("size",
|
||||
cl::desc("The estimated size of the generated function (# of instrs)"),
|
||||
cl::init(100));
|
||||
static cl::opt<unsigned> SeedCL("seed", cl::desc("Seed used for randomness"),
|
||||
cl::init(0), cl::cat(StressCategory));
|
||||
|
||||
static cl::opt<std::string>
|
||||
OutputFilename("o", cl::desc("Override output filename"),
|
||||
cl::value_desc("filename"));
|
||||
static cl::opt<unsigned> SizeCL(
|
||||
"size",
|
||||
cl::desc("The estimated size of the generated function (# of instrs)"),
|
||||
cl::init(100), cl::cat(StressCategory));
|
||||
|
||||
static cl::opt<std::string> OutputFilename("o",
|
||||
cl::desc("Override output filename"),
|
||||
cl::value_desc("filename"),
|
||||
cl::cat(StressCategory));
|
||||
|
||||
static LLVMContext Context;
|
||||
|
||||
@ -738,6 +742,7 @@ int main(int argc, char **argv) {
|
||||
using namespace llvm;
|
||||
|
||||
InitLLVM X(argc, argv);
|
||||
cl::HideUnrelatedOptions({&StressCategory, &getColorCategory()});
|
||||
cl::ParseCommandLineOptions(argc, argv, "llvm codegen stress-tester\n");
|
||||
|
||||
auto M = std::make_unique<Module>("/tmp/autogen.bc", Context);
|
||||
|
@ -28,28 +28,32 @@
|
||||
|
||||
using namespace llvm;
|
||||
|
||||
cl::OptionCategory UndNameCategory("UndName Options");
|
||||
|
||||
cl::opt<bool> DumpBackReferences("backrefs", cl::Optional,
|
||||
cl::desc("dump backreferences"), cl::Hidden,
|
||||
cl::init(false));
|
||||
cl::init(false), cl::cat(UndNameCategory));
|
||||
cl::opt<bool> NoAccessSpecifier("no-access-specifier", cl::Optional,
|
||||
cl::desc("skip access specifiers"), cl::Hidden,
|
||||
cl::init(false));
|
||||
cl::init(false), cl::cat(UndNameCategory));
|
||||
cl::opt<bool> NoCallingConvention("no-calling-convention", cl::Optional,
|
||||
cl::desc("skip calling convention"),
|
||||
cl::Hidden, cl::init(false));
|
||||
cl::Hidden, cl::init(false),
|
||||
cl::cat(UndNameCategory));
|
||||
cl::opt<bool> NoReturnType("no-return-type", cl::Optional,
|
||||
cl::desc("skip return types"), cl::Hidden,
|
||||
cl::init(false));
|
||||
cl::init(false), cl::cat(UndNameCategory));
|
||||
cl::opt<bool> NoMemberType("no-member-type", cl::Optional,
|
||||
cl::desc("skip member types"), cl::Hidden,
|
||||
cl::init(false));
|
||||
cl::init(false), cl::cat(UndNameCategory));
|
||||
cl::opt<std::string> RawFile("raw-file", cl::Optional,
|
||||
cl::desc("for fuzzer data"), cl::Hidden);
|
||||
cl::desc("for fuzzer data"), cl::Hidden,
|
||||
cl::cat(UndNameCategory));
|
||||
cl::opt<bool> WarnTrailing("warn-trailing", cl::Optional,
|
||||
cl::desc("warn on trailing characters"), cl::Hidden,
|
||||
cl::init(false));
|
||||
cl::init(false), cl::cat(UndNameCategory));
|
||||
cl::list<std::string> Symbols(cl::Positional, cl::desc("<input symbols>"),
|
||||
cl::ZeroOrMore);
|
||||
cl::ZeroOrMore, cl::cat(UndNameCategory));
|
||||
|
||||
static bool msDemangle(const std::string &S) {
|
||||
int Status;
|
||||
@ -84,6 +88,7 @@ static bool msDemangle(const std::string &S) {
|
||||
int main(int argc, char **argv) {
|
||||
InitLLVM X(argc, argv);
|
||||
|
||||
cl::HideUnrelatedOptions({&UndNameCategory, &getColorCategory()});
|
||||
cl::ParseCommandLineOptions(argc, argv, "llvm-undname\n");
|
||||
|
||||
if (!RawFile.empty()) {
|
||||
|
Loading…
Reference in New Issue
Block a user