Commit af47efb
emulator: add a per-instruction LLIL test suite
Addresses review feedback that every LLIL instruction the emulator
implements should have at least one unit test. Adds emulator_il_test.py,
which builds LLIL directly with LowLevelILFunction (rather than lifting
assembly) so each of the 88 operations the emulator handles is exercised
in isolation: constants, register read/write and splits, the full
arithmetic/logic/shift/rotate/compare/bit families, the double-precision
multiply and divide/modulo ops, memory and stack, flags, control flow
(goto/if/jump/call/ret/syscall/...), and the nop/trap/undef/unimpl/
intrinsic specials.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 84abd97 commit af47efb
2 files changed
Lines changed: 462 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
45 | | - | |
46 | | - | |
47 | | - | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
48 | 53 | | |
49 | 54 | | |
50 | | - | |
51 | | - | |
52 | | - | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
53 | 58 | | |
54 | 59 | | |
55 | 60 | | |
| |||
0 commit comments