aboutsummaryrefslogtreecommitdiff
path: root/sim/testsuite
diff options
context:
space:
mode:
authorHans-Peter Nilsson <hp@axis.com>2022-02-14 23:50:18 +0100
committerHans-Peter Nilsson <hp@bitrange.com>2022-02-14 23:50:18 +0100
commit9d67b0a0978e9651db74aa667be793420e7e4817 (patch)
treee9dd361ebcf7b6ed476bf7b4acaa0dd2aa90a335 /sim/testsuite
parenta532eb7277ff64fb073e209d418b0a97f686c0e3 (diff)
downloadgdb-9d67b0a0978e9651db74aa667be793420e7e4817.zip
gdb-9d67b0a0978e9651db74aa667be793420e7e4817.tar.gz
gdb-9d67b0a0978e9651db74aa667be793420e7e4817.tar.bz2
sim cris: Correct PRIu32 to PRIx32
In 5ee0bc23a68f "sim: clean up bfd_vma printing" there was an additional introduction of PRIx32 and PRIu32 but just in sim/cris/sim-if.c. One type of bug was fixed in commit d16ce6e4d581 "sim: cris: fix memory setup typos" but one remained; the PRIu32 usage is wrong, as hex output is desired; note the 0x prefix. Without this fix, you'll see output like: memory map 0:0x4000..0x5fff (8192 bytes) overlaps 0:0x0..0x16383 (91012 bytes) program stopped with signal 6 (Aborted). for some C programs, like some of the ones in the sim/cris/c testsuite from where the example is taken (freopen2.c). The bug behavior was with memory allocation. With an attempt to allocate memory using the brk syscall such that the room up to the next 8192-byte "page boundary" wasn't sufficient, the simulator memory allocation machinery horked on a consistency error when trying to allocate a memory block to raise the "end of the data segment": there was already memory allocated at that address. Unfortunately, none of the programs in sim/cris/asm exposed this bug at the time, but an assembler test-case is committed after this fix. sim/cris: * sim-if.c (sim_open): Correct PRIu32 to PRIx32.
Diffstat (limited to 'sim/testsuite')
0 files changed, 0 insertions, 0 deletions