Michael Tokarev
96420a30e0
tests/: spelling fixes
...
with some rewording in
tests/qemu-iotests/298
tests/qtest/fuzz/generic_fuzz.c
tests/unit/test-throttle.c
as suggested by Eric.
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru >
Reviewed-by: Eric Blake <eblake@redhat.com >
2023-09-08 13:08:52 +03:00
Richard Henderson
c6a5fc2ac7
decodetree: Add --output-null for meson testing
...
Using "-o /dev/null" fails on Windows. Rather that working
around this in meson, add a separate command-line option so
that we can use python's os.devnull.
Reported-by: Thomas Huth <thuth@redhat.com >
Fixes: 656666dc7d ("tests/decode: Convert tests to meson")
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Reviewed-by: Thomas Huth <thuth@redhat.com >
Message-Id: <20230531232510.66985-1-richard.henderson@linaro.org >
2023-05-31 19:56:42 -07:00
Peter Maydell and Richard Henderson
276d77de50
tests/decode: Add tests for various named-field cases
...
Add some tests for various cases of named-field use, both ones that
should work and ones that should be diagnosed as errors.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
Reviewed-by: Richard Henderson <richard.henderson@linaro.org >
Message-Id: <20230523120447.728365-7-peter.maydell@linaro.org >
2023-05-30 10:55:39 -07:00
Richard Henderson
656666dc7d
tests/decode: Convert tests to meson
...
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2023-05-30 10:55:39 -07:00
Richard Henderson
af93ccacc7
decodetree: Extend argument set syntax to allow types
...
Rather than force all structure members to be 'int',
allow the type of the member to be specified.
Reviewed-by: Luis Pires <luis.pires@eldorado.org.br >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2021-05-01 11:45:35 -07:00
Richard Henderson and Peter Maydell
acfdd2398d
decodetree: Improve identifier matching
...
Only argument set members have to be C identifiers, everything
else gets prefixed during conversion to C. Some places just
checked the leading character, and some places matched a leading
character plus a C identifier.
Convert everything to match full identifiers, including the
[&%@&] prefix, and drop the full C identifier requirement.
Reported-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org >
Message-id: 20200903192334.1603773-1-richard.henderson@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org >
2020-09-14 14:23:19 +01:00
Richard Henderson
fe079aa13d
decodetree: Drop check for less than 2 patterns in a group
...
While it makes little sense for the end product to have a group
containing only a single pattern, avoiding this case within an
incremental patch set is troublesome.
Because this is expected to be a transient condition, do not
bother "optimizing" this case, e.g. by folding away the group.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2020-06-09 09:19:48 -07:00
Richard Henderson
33c0f25bfd
tests/decode: Test non-overlapping groups
...
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2020-06-08 11:09:48 -07:00
Richard Henderson
b44b3449a0
decodetree: Allow group covering the entire insn space
...
This is an edge case for sure, but the logic that disallowed
this case was faulty. Further, a few fixes scattered about
can allow this to work.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2020-06-08 10:36:47 -07:00
Richard Henderson
94597b6146
decodetree: Allow !function with no input bits
...
Call this form a "parameter", returning a value extracted
from the DisasContext.
Reviewed-by: Philippe Mathieu-Daude <philmd@redhat.com >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2019-08-19 08:03:41 -07:00
Richard Henderson
2decfc9558
decodetree: Properly diagnose fields overflowing an insn
...
Previously this would result in an exception for shifting
the field mask by a negative number.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2019-03-12 09:46:58 -07:00
Bastian Koppelmann and Richard Henderson
bf92118fa9
test/decode: Add tests for PatternGroups
...
This adds one test that supposed to succeed to test deep nesting
of pattern groups which is rarely exercised by targets using decode
tree. The remaining tests exercise various fail conditions.
Signed-off-by: Bastian Koppelmann <kbastian@mail.uni-paderborn.de >
Message-Id: <20190227120217.20794-1-kbastian@mail.uni-paderborn.de >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2019-03-12 09:46:58 -07:00
Richard Henderson
0eff2df4a2
decodetree: Allow grouping of overlapping patterns
...
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2019-03-12 09:46:58 -07:00
Richard Henderson
568ae7efae
scripts: Add decodetree.py
...
To be used to decode ARM SVE, but could be used for any fixed-width ISA.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org >
Signed-off-by: Richard Henderson <richard.henderson@linaro.org >
2018-02-22 15:44:07 -08:00