Skip to content
This repository was archived by the owner on Nov 1, 2021. It is now read-only.

Commit 5b4cc3f

Browse files
committed
llvm-cov: Accept the long forms of gcov options
This is a bit imperfect, as these options don't show up in the help as is and single dash variants are accepted, which differs from gcov. Unfortunately, this seems to be as good as it gets with the cl::opt machinery, so it'll do as an incremental step. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@200419 91177308-0d34-0410-b5e6-96231b3b80d8
1 parent c8662b1 commit 5b4cc3f

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Diff for: tools/llvm-cov/llvm-cov.cpp

+6
Original file line numberDiff line numberDiff line change
@@ -26,20 +26,26 @@ static cl::opt<std::string> SourceFile(cl::Positional, cl::Required,
2626

2727
static cl::opt<bool> AllBlocks("a", cl::init(false),
2828
cl::desc("Display all basic blocks"));
29+
static cl::alias AllBlocksA("all-blocks", cl::aliasopt(AllBlocks));
2930

3031
static cl::opt<bool> BranchProb("b", cl::init(false),
3132
cl::desc("Display branch probabilities"));
33+
static cl::alias BranchProbA("branch-probabilities", cl::aliasopt(BranchProb));
3234

3335
static cl::opt<bool> BranchCount("c", cl::init(false),
3436
cl::desc("Display branch counts instead "
3537
"of percentages (requires -b)"));
38+
static cl::alias BranchCountA("branch-counts", cl::aliasopt(BranchCount));
3639

3740
static cl::opt<bool> FuncSummary("f", cl::init(false),
3841
cl::desc("Show coverage for each function"));
42+
static cl::alias FuncSummaryA("function-summaries", cl::aliasopt(FuncSummary));
3943

4044
static cl::opt<bool> UncondBranch("u", cl::init(false),
4145
cl::desc("Display unconditional branch info "
4246
"(requires -b)"));
47+
static cl::alias UncondBranchA("unconditional-branches",
48+
cl::aliasopt(UncondBranch));
4349

4450
static cl::OptionCategory DebugCat("Internal and debugging options");
4551
static cl::opt<bool> DumpGCOV("dump", cl::init(false), cl::cat(DebugCat),

0 commit comments

Comments
 (0)