]> git.ipfire.org Git - thirdparty/valgrind.git/commit
Add program to double-check VEX constant folding. BZ 506211
authorFlorian Krohm <flo2030@eich-krohm.de>
Sat, 12 Jul 2025 13:32:14 +0000 (13:32 +0000)
committerFlorian Krohm <flo2030@eich-krohm.de>
Sat, 12 Jul 2025 13:32:14 +0000 (13:32 +0000)
commit1752297cb1d7f3e112104f377d8ee5b99d55408b
tree307cae7cbd82c32bcf4c6a0ec36e51a6a63d00a2
parentd7743540064c58d3dcb850804fb29f742757d853
Add program to double-check VEX constant folding. BZ 506211

Using IR injection. Essentially:
- prepare input values for an IROp
- create an IRExpr for the IRop
- constant fold the expression
- make sure the result is an IRConst with the expected value

Only IROps with integer operands and result are supported.
No vector and floating point IROps. Maximum bit width is 64.

Part of fixing https://bugs.kde.org/show_bug.cgi?id=506211
20 files changed:
.gitignore
Makefile.am
VEX/priv/ir_inject.c
VEX/priv/ir_opt.c
VEX/pub/libvex.h
VEX/pub/libvex_ir.h
configure.ac
none/tests/iropt-test/Makefile.am [new file with mode: 0644]
none/tests/iropt-test/binary.c [new file with mode: 0644]
none/tests/iropt-test/filter_stderr [new file with mode: 0755]
none/tests/iropt-test/irops.tab [new file with mode: 0644]
none/tests/iropt-test/iropt-test-sec.stderr.exp [new file with mode: 0644]
none/tests/iropt-test/iropt-test-sec.vgtest [new file with mode: 0644]
none/tests/iropt-test/iropt-test.stderr.exp [new file with mode: 0644]
none/tests/iropt-test/iropt-test.vgtest [new file with mode: 0644]
none/tests/iropt-test/main.c [new file with mode: 0644]
none/tests/iropt-test/unary.c [new file with mode: 0644]
none/tests/iropt-test/util.c [new file with mode: 0644]
none/tests/iropt-test/valgrind.c [new file with mode: 0644]
none/tests/iropt-test/vtest.h [new file with mode: 0644]