1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 11:13:28 +01:00
llvm-mirror/utils
Eric Fiselier 9d535a8342 [lit] Support custom parsers in parseIntegratedTestScript
Summary:
Libc++ frequently has the need to parse more than just the builtin *test keywords* (`RUN`, `REQUIRES`, `XFAIL`, ect). For example libc++ currently needs a new keyword `MODULES-DEFINES: macro list...`. Instead of re-implementing the script parsing in libc++ this patch allows `parseIntegratedTestScript` to take custom parsers.

This patch introduces a new class `IntegratedTestKeywordParser` which implements the logic to parse/process a test keyword. Parsing of various keyword "kinds" are supported out of the box, including 'TAG', 'COMMAND', and 'LIST', which parse keywords such as `END.`, `RUN:` and `XFAIL:` respectively.

As an example after this change libc++ can implement the `MODULES-DEFINES` simply using: 
```
mparser = IntegratedTestKeywordParser('MODULES-DEFINES:', ParserKind.LIST)
parseIntegratedTestScript(test, additional_parsers=[mparser])
macro_list = mparser.getValue()
```


Reviewers: ddunbar, modocache, rnk, danalbert, jroelofs

Subscribers: mgrang, llvm-commits, cfe-commits

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

llvm-svn: 288694
2016-12-05 20:21:21 +00:00
..
abtest abtest: Cleanup, improve comments 2016-03-26 04:07:55 +00:00
bugpoint
count Remove autoconf support 2016-01-26 21:29:08 +00:00
crosstool
emacs Cleaning up LLVM IR mode for Emacs. 2015-09-10 13:44:28 +00:00
FileCheck FileCheck: Minor cleanup of the class Pattern 2016-08-26 16:18:40 +00:00
fpcmp Remove autoconf support 2016-01-26 21:29:08 +00:00
gdb-scripts Fix gdb pretty printers to work with Python 3. 2016-08-05 16:48:31 +00:00
git
git-svn [git-llvm] Use --force-interactive when commiting to enable SVN to prompt password 2016-11-30 19:12:53 +00:00
jedit Rename all references to old mailing lists to new lists.llvm.org address. 2015-08-05 03:51:17 +00:00
kate Rename all references to old mailing lists to new lists.llvm.org address. 2015-08-05 03:51:17 +00:00
KillTheDoctor Explicitly specify the ANSI version of these Win32 APIs. While these are seemingly unrelated changes, they are all NFC because we currently default to the ANSI versions of the APIs when building for Windows. This simply makes the ANSI usage explicit. 2016-06-23 14:45:54 +00:00
lint
lit [lit] Support custom parsers in parseIntegratedTestScript 2016-12-05 20:21:21 +00:00
llvm-build llvm-config: Add preliminary Windows support 2016-02-09 19:41:14 +00:00
llvm-lit Fix llvm-lit.in corresponding to r283710. 2016-10-10 23:02:42 +00:00
LLVMVisualizers Improved Visual Studio 2015 visualization of SmallVectorImpl 2016-06-13 01:43:14 +00:00
Misc Delete mergefunctions.clang.svn.patch 2016-04-12 19:44:40 +00:00
not Remove unused header, NFC. 2016-12-01 19:38:48 +00:00
opt-viewer [opt-viewer] Add support for libYAML for faster parsing 2016-11-15 08:40:51 +00:00
PerfectShuffle Remove autoconf support 2016-01-26 21:29:08 +00:00
release Print correct directory in merge script. 2016-11-11 23:26:28 +00:00
TableGen TableGen/AsmMatcherEmitter: Bring sorting check back under EXPENSIVE_CHECKS 2016-12-05 19:44:31 +00:00
Target/ARM
testgen
textmate
unittest [cmake] Export gtest/gtest_main and its dependencies via a special build tree only cmake exports file. 2016-09-09 19:45:34 +00:00
valgrind
vim vim: special case the CHECK prefix 2016-11-03 15:56:06 +00:00
yaml-bench Timer: Track name and description. 2016-11-18 19:43:18 +00:00
bisect
check-each-file
clang-parse-diagnostics-file
codegen-diff
countloc.sh
create_ladder_graph.py Add ladder graph utility 2015-04-14 18:14:38 +00:00
DSAclean.py
DSAextract.py
extract_symbols.py Handle non-inlined clang::Type::getAs specializations in extract_symbols.py 2016-11-14 17:07:09 +00:00
findmisopt
findoptdiff Remove the ScalarReplAggregates pass 2016-06-15 00:19:09 +00:00
findsym.pl
GenLibDeps.pl Remove bit-rotten CppBackend. 2016-05-05 14:35:40 +00:00
GetRepositoryPath
GetSourceVersion
getsrcs.sh
lldbDataFormatters.py
llvm-compilers-check
llvm-native-gxx
llvm.grm
LLVMBuild.txt
llvmdo
llvmgrep Use -H on darwin as well. 2012-01-26 22:06:23 +00:00
makellvm
prepare-code-coverage-artifact.py [utils] Add a '--unified-report' option to the code coverage prep script 2016-10-26 22:07:39 +00:00
schedcover.py [MISched] Python script to check coverage of misched info 2015-10-12 08:50:47 +00:00
shuffle_fuzz.py [Utils] Updated shuffle fuzz script to generate more modern (valid) IR. 2015-11-22 16:04:32 +00:00
sort_includes.py Add polly support to sort_includes.py 2015-05-09 09:08:56 +00:00
test_debuginfo.pl
update_llc_test_checks.py [X86] Fix test checks script to satisfy pyflakes 2016-11-07 18:08:19 +00:00
update_test_checks.py [X86][AVX512] Add support for masked shuffle comments 2016-07-03 13:08:29 +00:00
UpdateCMakeLists.pl Generalize matching of add_executable to add_XXX_executable. 2012-11-22 07:48:52 +00:00
wciia.py