aboutsummaryrefslogtreecommitdiff
path: root/binutils
diff options
context:
space:
mode:
authorJens Remus <jremus@linux.ibm.com>2024-03-01 12:45:14 +0100
committerJens Remus <jremus@linux.ibm.com>2024-03-01 12:45:14 +0100
commit75a28d1a97ace81c8481fd1c85d21e6f22e68924 (patch)
treead764109e3f3fa1a0228078d50c6e35210589286 /binutils
parentdfa4ac9728ce8999a9b53d1ef37b175380940ee5 (diff)
downloadgdb-75a28d1a97ace81c8481fd1c85d21e6f22e68924.zip
gdb-75a28d1a97ace81c8481fd1c85d21e6f22e68924.tar.gz
gdb-75a28d1a97ace81c8481fd1c85d21e6f22e68924.tar.bz2
s390: Print base register 0 as "0" in disassembly
Base and index register 0 have no effect in address computation: "A value of zero in the B [base] or X [index] field specifies that no base or index is to be applied, and, thus, general register 0 cannot be designated as containing a base address or index." IBM z/Architecture Principles of Operation [1], chapter "Organization", section "General Registers". Index register 0 is omitted in the s390 disassembly. Base register 0 is omitted in D(B), D(L,B) and D(X,B) - the latter only if the index register is zero. To make it more apparent print base register 0 as "0" instead of "%r0", whenever it would still be printed in the disassembly. [1]: IBM z/Architecture Principles of Operation, SA22-7832-13, https://publibfp.dhe.ibm.com/epubs/pdf/a227832d.pdf opcodes/ * s390-dis.c: Print base register 0 as "0" in disassembly. binutils/ * NEWS: Mention base register 0 now being printed as "0" in s390 disassembly. gas/ * testsuite/gas/s390/zarch-base-index-0.d: Update test case output verification patterns to accept "0" as base base register due to disassembler output format change. * gas/testsuite/gas/s390/zarch-omitted-base-index.d: Likewise. Reviewed-by: Andreas Krebbel <krebbel@linux.ibm.com> Signed-off-by: Jens Remus <jremus@linux.ibm.com>
Diffstat (limited to 'binutils')
-rw-r--r--binutils/NEWS2
1 files changed, 2 insertions, 0 deletions
diff --git a/binutils/NEWS b/binutils/NEWS
index 7b7ac1c..9c7c8f1 100644
--- a/binutils/NEWS
+++ b/binutils/NEWS
@@ -1,5 +1,7 @@
-*- text -*-
+* Base register 0 is now printed as "0" instead of "%r0" in s390 disassembly.
+
* When objdump or readelf are used to display the contents of a .eh_frame
section they will now also display the contents of the .eh_frame_hdr section,
if present.