mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 04:02:41 +01:00
fcd363afd3
In input dump annotations, `check:2'1` indicates diagnostic 1 for the `CHECK` directive on check file line 2. Without this patch, `-dump-input` computes the diagnostic index with the assumption that FileCheck *consecutively* produces all diagnostics for the same pattern. Already, that can be a false assumption, as in the examples below. Moreover, it seems like a brittle assumption as FileCheck evolves. Finally, it actually complicates the implementation even if it makes it slightly more efficient. This patch avoids that assumption. Examples below show results after applying this patch. Before applying this patch, `'N` is omitted throughout these examples because the implementation doesn't notice there's more than one diagnostic per pattern. First, `CHECK-LABEL` violates the assumption because `CHECK-LABEL` tries to match twice, and other directives can match in between: ``` $ cat check CHECK: foobar CHECK-LABEL: foobar $ FileCheck -vv check < input |& tail -8 <<<<<< 1: text 2: foobar label:2'0 ^~~~~~ check:1 ^~~~~~ label:2'1 X error: no match found 3: text >>>>>> ``` Second, `--implicit-check-not` is obviously processed many times among other directives: ``` $ cat check CHECK: foo CHECK: foo $ FileCheck -vv -dump-input=always -implicit-check-not=foo \ check < input |& tail -16 <<<<<< 1: text not:imp1'0 X~~~~ 2: foo check:1 ^~~ not:imp1'1 X 3: text not:imp1'1 ~~~~~ 4: foo check:2 ^~~ not:imp1'2 X 5: text not:imp1'2 ~~~~~ 6: eof:2 ^ >>>>>> ``` Reviewed By: thopre, jhenderson Differential Revision: https://reviews.llvm.org/D97813 |
||
---|---|---|
.. | ||
benchmark | ||
bugpoint | ||
count | ||
crosstool | ||
docker | ||
emacs | ||
FileCheck | ||
fpcmp | ||
gdb-scripts | ||
git | ||
gn | ||
jedit | ||
kate | ||
KillTheDoctor | ||
lint | ||
lit | ||
llvm-lit | ||
llvm-locstats | ||
LLVMVisualizers | ||
Misc | ||
not | ||
PerfectShuffle | ||
release | ||
Reviewing | ||
sanitizers | ||
TableGen | ||
Target/ARM | ||
testgen | ||
textmate | ||
unittest | ||
UpdateTestChecks | ||
valgrind | ||
vim | ||
vscode | ||
yaml-bench | ||
abtest.py | ||
add_argument_names.py | ||
bisect | ||
bisect-skip-count | ||
bugpoint_gisel_reducer.py | ||
check_ninja_deps.py | ||
check-each-file | ||
chunk-print-before-all.py | ||
clang-parse-diagnostics-file | ||
codegen-diff | ||
collect_and_build_with_pgo.py | ||
convert-constraint-log-to-z3.py | ||
countloc.sh | ||
create_ladder_graph.py | ||
demangle_tree.py | ||
DSAclean.py | ||
DSAextract.py | ||
extract_symbols.py | ||
extract_vplan.py | ||
extract-section.py | ||
findmisopt | ||
findoptdiff | ||
findsym.pl | ||
GenLibDeps.pl | ||
GetSourceVersion | ||
getsrcs.sh | ||
indirect_calls.py | ||
lldbDataFormatters.py | ||
llvm-compilers-check | ||
llvm-gisel-cov.py | ||
llvm-native-gxx | ||
llvm-original-di-preservation.py | ||
llvm.grm | ||
llvmdo | ||
llvmgrep | ||
merge-stats.py | ||
prepare-code-coverage-artifact.py | ||
remote-exec.py | ||
schedcover.py | ||
shuffle_fuzz.py | ||
shuffle_select_fuzz_tester.py | ||
sort_includes.py | ||
sysroot.py | ||
unicode-case-fold.py | ||
update_analyze_test_checks.py | ||
update_cc_test_checks.py | ||
update_llc_test_checks.py | ||
update_mca_test_checks.py | ||
update_mir_test_checks.py | ||
update_test_checks.py | ||
update_test_prefix.py | ||
UpdateCMakeLists.pl | ||
wciia.py |