diff options
author | Ulrich Weigand <uweigand@de.ibm.com> | 2011-12-19 21:44:57 +0000 |
---|---|---|
committer | Ulrich Weigand <uweigand@de.ibm.com> | 2011-12-19 21:44:57 +0000 |
commit | 8de7d199bbcce5fffad187294a57106ad82af16b (patch) | |
tree | 22fbca5cf1cac4cc32fa90d114541e90f6daa762 /gdb | |
parent | 83896202bf93a490c4b8e6a222903d5797e16b32 (diff) | |
download | gdb-8de7d199bbcce5fffad187294a57106ad82af16b.zip gdb-8de7d199bbcce5fffad187294a57106ad82af16b.tar.gz gdb-8de7d199bbcce5fffad187294a57106ad82af16b.tar.bz2 |
* s390-tdep.c (s390_push_dummy_call): Set addressing mode bit
in return PSWA.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/s390-tdep.c | 10 |
2 files changed, 13 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index c433ef1..16748d1 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2011-12-19 Ulrich Weigand <uweigand@de.ibm.com> + + * s390-tdep.c (s390_push_dummy_call): Set addressing mode bit + in return PSWA. + 2011-12-19 Tom Tromey <tromey@redhat.com> * symtab.h (add_minsym_to_hash_table): Don't declare. diff --git a/gdb/s390-tdep.c b/gdb/s390-tdep.c index 1c09739..cd0ef9c 100644 --- a/gdb/s390-tdep.c +++ b/gdb/s390-tdep.c @@ -2749,9 +2749,15 @@ s390_push_dummy_call (struct gdbarch *gdbarch, struct value *function, } } - /* Store return address. */ + /* Store return PSWA. In 31-bit mode, keep addressing mode bit. */ + if (word_size == 4) + { + ULONGEST pswa; + regcache_cooked_read_unsigned (regcache, S390_PSWA_REGNUM, &pswa); + bp_addr = (bp_addr & 0x7fffffff) | (pswa & 0x80000000); + } regcache_cooked_write_unsigned (regcache, S390_RETADDR_REGNUM, bp_addr); - + /* Store updated stack pointer. */ regcache_cooked_write_unsigned (regcache, S390_SP_REGNUM, sp); |