diff options
author | Andrew Cagney <cagney@redhat.com> | 1998-04-02 03:27:24 +0000 |
---|---|---|
committer | Andrew Cagney <cagney@redhat.com> | 1998-04-02 03:27:24 +0000 |
commit | 725fc5d927e599b2a7785e2318cf3012e2c98ee0 (patch) | |
tree | cb4ce48cdbfbf7f2e72dc2c5954eb8716cad5d9a /sim/mips/interp.c | |
parent | 3dcac15f1f3f940d7f5dad402155dec74291432b (diff) | |
download | gdb-725fc5d927e599b2a7785e2318cf3012e2c98ee0.zip gdb-725fc5d927e599b2a7785e2318cf3012e2c98ee0.tar.gz gdb-725fc5d927e599b2a7785e2318cf3012e2c98ee0.tar.bz2 |
For mips get_mem_size call. Force the return of a 32 bit value
regardless of the target's word bitsize.
Diffstat (limited to 'sim/mips/interp.c')
-rw-r--r-- | sim/mips/interp.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sim/mips/interp.c b/sim/mips/interp.c index 3268ab1..7be7ac6 100644 --- a/sim/mips/interp.c +++ b/sim/mips/interp.c @@ -1123,9 +1123,12 @@ sim_monitor (SIM_DESC sd, /* [A0 + 4] = instruction cache size */ /* [A0 + 8] = data cache size */ { - address_word value = MEM_SIZE /* FIXME STATE_MEM_SIZE (sd) */; + unsigned_4 value = MEM_SIZE /* FIXME STATE_MEM_SIZE (sd) */; + unsigned_4 zero = 0; H2T (value); - sim_write (sd, A0, (char *)&value, sizeof (value)); + sim_write (sd, A0 + 0, (char *)&value, 4); + sim_write (sd, A0 + 4, (char *)&zero, 4); + sim_write (sd, A0 + 8, (char *)&zero, 4); /* sim_io_eprintf (sd, "sim: get_mem_info() depreciated\n"); */ break; } |