aboutsummaryrefslogtreecommitdiff
path: root/tests/expected/runrom/overflow-arithmetics.txt
diff options
context:
space:
mode:
authorMiquel Sabaté Solà <mssola@mssola.com>2026-10-09 21:45:05 +0200
committerMiquel Sabaté Solà <mssola@mssola.com>2026-10-09 21:45:05 +0200
commitf6df4314945c1d37d314a7c88553b97b23c748e9 (patch)
tree20e71c89c25f469a83c52528dfdfe0ed71a8c3e1 /tests/expected/runrom/overflow-arithmetics.txt
parentaa5174fc055dc66e78a8aa7030c018e43cf588a1 (diff)
downloadtools.nes-f6df4314945c1d37d314a7c88553b97b23c748e9.tar.gz
tools.nes-f6df4314945c1d37d314a7c88553b97b23c748e9.zip
vnf,runrom: detect bad data access
This includes detection for: - Stack underflows (it was theoretically already there but it had never been properly tested). - Load/store out of bounds for a given variable known via the .nasm/ directory. - Load out of bounds on a set of data referenced via a raw label (see commit aa5174fc055d ("xixanta: Add an hint for the ending of data labels")). Signed-off-by: Miquel Sabaté Solà <mssola@mssola.com>
Diffstat (limited to 'tests/expected/runrom/overflow-arithmetics.txt')
-rw-r--r--tests/expected/runrom/overflow-arithmetics.txt6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/expected/runrom/overflow-arithmetics.txt b/tests/expected/runrom/overflow-arithmetics.txt
new file mode 100644
index 0000000..3eadfae
--- /dev/null
+++ b/tests/expected/runrom/overflow-arithmetics.txt
@@ -0,0 +1,6 @@
+<start> PC: $8011, cycles: 7, registers: [a: $00, x: $00, y: $00, sp: $FD], status: ----I--
+ldx #$01 PC: $8013, cycles: 9, registers: [a: $00, x: $01, y: $00, sp: $FD], status: ----I--
+
+@:
+lda $0F, x PC: $8013, cycles: 9, registers: [a: $00, x: $01, y: $00, sp: $FD], status: ----I--
+error: out of bounds: indexed access to $0010 falls out of 'zp_buffer' ($00-$10; bounded inclusively below and exclusively above)