CommandFlags.h/llc: Move StopAfter/StartBefore options to llc.

Move those two options to llc:

The options in CommandFlags.h are shared by dsymutil, gold, llc,
llvm-dwp, llvm-lto, llvm-mc, lto, opt.

-stop-after/-start-after only affect codegen passes however only gold and llc
actually create codegen passes and I believe these flags to be only
useful for users of llc. For the other tools they are just highly
confusing: -stop-after claims to "Stop compilation after a specific
pass" which is not true in the context of the "opt" tool.

Differential Revision: https://reviews.llvm.org/D23050

llvm-svn: 277551
This commit is contained in:
Matthias Braun 2016-08-02 23:36:06 +00:00
parent 4babac89cc
commit 9dbdc18523
2 changed files with 8 additions and 9 deletions

View File

@ -221,15 +221,6 @@ UseCtors("use-ctors",
cl::desc("Use .ctors instead of .init_array."),
cl::init(false));
cl::opt<std::string> StopAfter("stop-after",
cl::desc("Stop compilation after a specific pass"),
cl::value_desc("pass-name"),
cl::init(""));
cl::opt<std::string> StartAfter("start-after",
cl::desc("Resume compilation after a specific pass"),
cl::value_desc("pass-name"),
cl::init(""));
cl::opt<bool> DataSections("data-sections",
cl::desc("Emit data into separate sections"),
cl::init(false));

View File

@ -118,6 +118,14 @@ static cl::opt<bool> DiscardValueNames(
cl::desc("Discard names from Value (other than GlobalValue)."),
cl::init(false), cl::Hidden);
static cl::opt<std::string> StopAfter("stop-after",
cl::desc("Stop compilation after a specific pass"),
cl::value_desc("pass-name"), cl::init(""));
static cl::opt<std::string> StartAfter("start-after",
cl::desc("Resume compilation after a specific pass"),
cl::value_desc("pass-name"), cl::init(""));
namespace {
static ManagedStatic<std::vector<std::string>> RunPassNames;