aboutsummaryrefslogtreecommitdiff
path: root/llvm/utils/FileCheck/FileCheck.cpp
diff options
context:
space:
mode:
authorJoel E. Denny <jdenny.ornl@gmail.com>2020-07-10 17:13:25 -0400
committerJoel E. Denny <jdenny.ornl@gmail.com>2020-07-10 17:21:01 -0400
commit6dda6ff0e094b667311dbd7a46d4e36aa787e033 (patch)
tree72ca79f88ee97c1106f11d4c27d394268d655c87 /llvm/utils/FileCheck/FileCheck.cpp
parentec2f2cec769cb07bbf8691f2e0e800747266f857 (diff)
downloadllvm-6dda6ff0e094b667311dbd7a46d4e36aa787e033.zip
llvm-6dda6ff0e094b667311dbd7a46d4e36aa787e033.tar.gz
llvm-6dda6ff0e094b667311dbd7a46d4e36aa787e033.tar.bz2
[FileCheck] Fix up -dump-input* docs
In FileCheck.rst, add `-dump-input-context` and `-dump-input-filter`, and fix some `-dump-input` documentation. In `FileCheck -help`, `cl::value_desc("kind")` is being ignored for `-dump-input-filter`, so just drop it. Extend `-dump-input=help` to mention FILECHECK_OPTS.
Diffstat (limited to 'llvm/utils/FileCheck/FileCheck.cpp')
-rw-r--r--llvm/utils/FileCheck/FileCheck.cpp16
1 files changed, 11 insertions, 5 deletions
diff --git a/llvm/utils/FileCheck/FileCheck.cpp b/llvm/utils/FileCheck/FileCheck.cpp
index 8bf1dd2..fa79c5e 100644
--- a/llvm/utils/FileCheck/FileCheck.cpp
+++ b/llvm/utils/FileCheck/FileCheck.cpp
@@ -140,12 +140,11 @@ enum DumpInputFilterValue {
static cl::list<DumpInputFilterValue> DumpInputFilters(
"dump-input-filter",
cl::desc("In the dump requested by -dump-input, print only input lines of\n"
- "kind <kind> plus any context specified by -dump-input-context.\n"
- "When there are multiple occurrences of this option, the <kind>\n"
+ "kind <value> plus any context specified by -dump-input-context.\n"
+ "When there are multiple occurrences of this option, the <value>\n"
"that appears earliest in the list below has precedence. The\n"
"default is 'error' when -dump-input=fail, and it's 'all' when\n"
"-dump-input=always.\n"),
- cl::value_desc("kind"),
cl::values(clEnumValN(DumpInputFilterAll, "all", "All input lines"),
clEnumValN(DumpInputFilterAnnotationFull, "annotation-full",
"Input lines with annotations"),
@@ -226,14 +225,21 @@ static void DumpInputAnnotationHelp(raw_ostream &OS) {
<< "explain the input dump printed by FileCheck.\n"
<< "\n"
<< "Related command-line options:\n"
+ << "\n"
<< " - -dump-input=<value> enables or disables the input dump\n"
- << " - -dump-input-filter=<kind> filters the input lines\n"
+ << " - -dump-input-filter=<value> filters the input lines\n"
<< " - -dump-input-context=<N> adjusts the context of filtered lines\n"
<< " - -v and -vv add more annotations\n"
<< " - -color forces colors to be enabled both in the dump and below\n"
<< " - -help documents the above options in more detail\n"
<< "\n"
- << "Input dump annotation format:\n";
+ << "These options can also be set via FILECHECK_OPTS. For example, for\n"
+ << "maximum debugging output on failures:\n"
+ << "\n"
+ << " $ FILECHECK_OPTS='-dump-input-filter=all -vv -color' ninja check\n"
+ << "\n"
+ << "Input dump annotation format:\n"
+ << "\n";
// Labels for input lines.
OS << " - ";