summaryrefslogtreecommitdiff
path: root/scripts/update_lit_checks.py
Commit message (Collapse)AuthorAgeFilesLines
* Match names more precisely in update_lit_checks.py (#6190)Thomas Lively2024-01-021-6/+14
| | | | | | | | | | Previously the lit test update script interpreted module names as the names of import items and export names as the names of export items, but it is more precise to use the actual identifiers of the imported or exported items as the names instead. Update update_lit_checks.py to use a more correct regex to match names and to correctly use the identifiers of import and export items as their names. In some cases this can improve the readability of test output.
* Drop support for non-standard quoted function names (#6188)Thomas Lively2023-12-201-3/+7
| | | | | | | | | | | | | | | | | | We previously supported a non-standard `(func "name" ...` syntax for declaring functions exported with the quoted name. Since that is not part of the standard text format, drop support for it, replacing it with the standard `(func $name (export "name") ...` syntax instead. Also replace our other usage of the quoted form in our text output, which was where we quoted names containing characters that are not allowed to appear in standard names. To handle that case, adjust our output from `"$name"` to `$"name"`, which is the standards-track way of supporting such names. Also fix how we detect non-standard name characters to match the spec. Update the lit test output generation script to account for these changes, including by making the `$` prefix on names mandatory. This causes the script to stop interpreting declarative element segments with the `(elem declare ...` syntax as being named "declare", so prevent our generated output from regressing by counting "declare" as a name in the script.
* Support '%S' placeholder in update_lit_checks.py (#6075)Alexander Guryanov2023-11-021-0/+1
|
* Fuzzer: Ignore host limits (#5536)Alon Zakai2023-03-011-0/+6
| | | | | We can't just skip host limits (#5534) but must also ignore execution at that point, as optimizations can change the results if they change whether we reach a host limit.
* [wasm-ctor-eval] Add v128 load/store support (#5512)Alon Zakai2023-02-231-0/+5
|
* Parse `rec` in update_lit_checks.py (#4784)Thomas Lively2022-07-081-1/+1
|
* Generate lit checks for fuzz-exec output (#4301)Thomas Lively2021-11-031-10/+48
| | | Use the new capability in a new test of RTT behavior that will be fixed in #4284,
* Detect erroneous use of "FileCheck" in update script (#4198)Thomas Lively2021-10-011-1/+4
| | | | | | | The upstream name of the command in LLVM is FileCheck, but we use a Python package called filecheck instead and using `FileCheck` in lit tests will not work. To make catching this common error easier, add a warning about it in scripts/update_lit_checks.py. This warning also applies to other uses of pipes, which are not supported in this script.
* Support generating checks for multiple modules (#3962)Thomas Lively2021-07-021-52/+94
| | | | | | In conjunction with the `foreach` tool, allows autogenerating checks for lit tests containing multiple modules. Supporting this will help automatically port existing bespoke wast tests to be lit tests, since many of those tests contain multiple modules per file.
* [NFC] Refactor update_lit_checks.py (#3964)Thomas Lively2021-07-021-111/+120
| | | | Decompose the code into more functions and make other simplifying changes to prepare for multi-module support introduced in #3962.
* Add option to add checks for all items (#3961)Thomas Lively2021-07-021-14/+44
| | | | | | | | Add an --all-items flag to update_lit_checks.py to emit checks for all module items, not just those that match items in the input. Update two tests to use generated input with the new flag. Also, to improve readability, insert an empty line between consecutive checks for different items.
* Generate FileCheck checks for all module items (#3957)Thomas Lively2021-06-281-31/+78
| | | | | | | | | | | | | | | | | | | | | | | | | | Instead of only generating checks for functions, generate checks for all named top-level module items, such as types, tags, tables, and memories. Because module items can be in different orders in the input and the output but FileCheck checks must follow the order of the output, we need to be slightly clever about when we emit the checks. Consider these types in the input file: ``` (type $A (...)) (type $B (...)) ``` If their order is reversed in the output file, then the checks for $B need to be emitted before the checks for $A, so the resulting module will look like this: ``` ;; CHECK: (type $B (...)) ;; CHECK: (type $A (...)) (type $A (...)) (type $B (...)) ``` Rather than this, which looks nicer but would be incorrect: ``` ;; CHECK: (type $A (...)) (type $A (...)) ;; CHECK: (type $B (...)) (type $B (...)) ```
* Introduce a script for updating lit tests (#3503)Thomas Lively2021-01-211-0/+179
And demonstrate its capabilities by porting all tests of the optimize-instructions pass to use lit and FileCheck.