diff options
author | Philippe Mathieu-Daudé <f4bug@amsat.org> | 2020-03-30 11:30:27 +0200 |
---|---|---|
committer | Philippe Mathieu-Daudé <f4bug@amsat.org> | 2020-07-11 11:02:05 +0200 |
commit | 2e34e622c2cbda6828bbb395b6bdd4e0240b8217 (patch) | |
tree | 9f05c073f3151c4c425d626c31bdf65743add99d /target/avr | |
parent | a291bc851d482907d643db990b70c1cdb98c730a (diff) | |
download | qemu-2e34e622c2cbda6828bbb395b6bdd4e0240b8217.zip qemu-2e34e622c2cbda6828bbb395b6bdd4e0240b8217.tar.gz qemu-2e34e622c2cbda6828bbb395b6bdd4e0240b8217.tar.bz2 |
target/avr/cpu: Fix $PC displayed address
$PC is 16-bit wide. Other registers display addresses on a byte
granularity.
To have a coherent ouput, display $PC using byte granularity too.
Reviewed-by: Thomas Huth <huth@tuxfamily.org>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20200707070021.10031-3-f4bug@amsat.org>
Diffstat (limited to 'target/avr')
-rw-r--r-- | target/avr/cpu.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/target/avr/cpu.c b/target/avr/cpu.c index 0cfc5f2..5d9c4ad 100644 --- a/target/avr/cpu.c +++ b/target/avr/cpu.c @@ -151,7 +151,7 @@ static void avr_cpu_dump_state(CPUState *cs, FILE *f, int flags) int i; qemu_fprintf(f, "\n"); - qemu_fprintf(f, "PC: %06x\n", env->pc_w); + qemu_fprintf(f, "PC: %06x\n", env->pc_w * 2); /* PC points to words */ qemu_fprintf(f, "SP: %04x\n", env->sp); qemu_fprintf(f, "rampD: %02x\n", env->rampD >> 16); qemu_fprintf(f, "rampX: %02x\n", env->rampX >> 16); |