]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
readelf .debug_aranges header display
authorAlan Modra <amodra@gmail.com>
Sun, 22 Feb 2026 04:52:43 +0000 (15:22 +1030)
committerAlan Modra <amodra@gmail.com>
Mon, 23 Feb 2026 01:05:14 +0000 (11:35 +1030)
Print "Address size" rather than "Pointer Size" and "Segment size"
rather than "Segment Size", using the same names and capitalisation
as is used when printing other headers with these fields.

binutils/
* dwarf.c
* testsuite/binutils-all/i386/compressed-1a.d
* testsuite/binutils-all/x86-64/compressed-1a.d
gas/
* testsuite/gas/aarch64/dwarf.d: Update expected output.
* testsuite/gas/i386/dw2-compress-3a.d: Likewise.
* testsuite/gas/i386/dw2-compress-3b.d: Likewise.
* testsuite/gas/i386/dw2-compressed-3a.d: Likewise.
* testsuite/gas/i386/dw2-compressed-3b.d: Likewise.
* testsuite/gas/elf/dwarf-5-irp.d: Likewise.
* testsuite/gas/elf/dwarf2-20.d: Likewise, and match mn10200
output, removing xfail.

binutils/dwarf.c
binutils/testsuite/binutils-all/i386/compressed-1a.d
binutils/testsuite/binutils-all/x86-64/compressed-1a.d
gas/testsuite/gas/aarch64/dwarf.d
gas/testsuite/gas/elf/dwarf-5-irp.d
gas/testsuite/gas/elf/dwarf2-20.d
gas/testsuite/gas/i386/dw2-compress-3a.d
gas/testsuite/gas/i386/dw2-compress-3b.d
gas/testsuite/gas/i386/dw2-compressed-3a.d
gas/testsuite/gas/i386/dw2-compressed-3b.d

index 46499ac243603a5562a47ae536bde2420f35341b..fa8dce25d44725b262e99c8ce1e6fd5c14ff6dd4 100644 (file)
@@ -9075,8 +9075,8 @@ display_debug_aranges (struct dwarf_section *section,
       printf (_("  Version:                  %d\n"), arange.ar_version);
       printf (_("  Offset into .debug_info:  %#" PRIx64 "\n"),
              arange.ar_info_offset);
-      printf (_("  Pointer Size:             %d\n"), arange.ar_address_size);
-      printf (_("  Segment Size:             %d\n"), arange.ar_segment_size);
+      printf (_("  Address size:             %d\n"), arange.ar_address_size);
+      printf (_("  Segment size:             %d\n"), arange.ar_segment_size);
 
       if (!address_size_ok (section->name, arange.ar_address_size,
                            arange.ar_segment_size))
index d8aabd668296cfc051d2f1f4c28817a58655cbb8..47b97771ef920d35c674d0e3a8178df7554f925b 100644 (file)
@@ -121,8 +121,8 @@ Contents of the .[z]?debug_aranges section:
   Length:                   28
   Version:                  2
   Offset into .[z]?debug_info:  (0x)?0
-  Pointer Size:             4
-  Segment Size:             0
+  Address size:             4
+  Segment size:             0
 
     Address    Length
     00000000 0000001b ?
index e125829bf0fcd7c31c2cb91ad8860ea13437ebdd..a1466ded5ff26acca13c3161f02b8c944d92ce79 100644 (file)
@@ -120,8 +120,8 @@ Contents of the .[z]?debug_aranges section:
   Length:                   44
   Version:                  2
   Offset into .[z]?debug_info:  (0x)?0
-  Pointer Size:             8
-  Segment Size:             0
+  Address size:             8
+  Segment size:             0
 
     Address            Length
     0000000000000000 0000000000000015 ?
index 226a71968fde2ba5c8ccd1571658769724936079..ee1b7bf293dbe5bf8c3d4cb40f1f686596762400 100644 (file)
@@ -21,8 +21,8 @@ Contents of the .debug_aranges section:
   Length:                   (44|28)
   Version:                  2
   Offset into .debug_info:  (0x)?0
-  Pointer Size:             (8|4)
-  Segment Size:             0
+  Address size:             (8|4)
+  Segment size:             0
 
     Address[ ]+Length
     0+ 0+8 ?
index 6bcdc6636a665832019e88c636e5f7f862aef95f..a4f01355db3dddecde168bdc90280df8b255492f 100644 (file)
@@ -89,8 +89,8 @@ Contents of the \.debug_aranges section:
   Length: .*
   Version: +2
   Offset into \.debug_info: .*
-  Pointer Size: +[248]
-  Segment Size: +0
+  Address size: +[248]
+  Segment size: +0
 
     Address +Length
     0+ [0-9a-f]+ ?
index 04673014457de6b1d01bf270d85973bf19d1df2f..99078f9233aff74a7719e54ba0ad81c0ec466904 100644 (file)
@@ -1,18 +1,16 @@
 #as: -gdwarf-3
 #readelf: -wr
 #name: DWARF2_20: debug ranges ignore non-code sections
-# The mn10200 target has a pointer size of 3, but it does not use segment selectors.  This confuses DWARF and readelf will complain.
-#xfail: mn102*-*
 # score-elf, tic6x-elf and xtensa-elf need special handling to support .nop 16
 #xfail: score-* tic6x-* xtensa-*
 
 Contents of the .debug_aranges section:
 
-[      ]+Length:[      ]+(16|28|44)
+[      ]+Length:[      ]+(16|20|28|44)
 [      ]+Version:.*
 [      ]+Offset into .debug_info:[     ]+(0x)?0
-[      ]+Pointer Size:[        ]+(2|4|8)
-[      ]+Segment Size:[        ]+0
+[      ]+Address size:[        ]+(2|3|4|8)
+[      ]+Segment size:[        ]+0
 
 [      ]+Address[      ]+Length
 [      ]+0+000 0+010 ?
index 0b990184da364c673ed3aa2bbaa5b7e8a7644e4c..fd0271084a76d68b5ffd1e61f17b40889321c96e 100644 (file)
@@ -58,8 +58,8 @@ Contents of the .debug_aranges section:
   Length:                   20
   Version:                  2
   Offset into .debug_info:  (0x)?0
-  Pointer Size:             4
-  Segment Size:             0
+  Address size:             4
+  Segment size:             0
 
     Address    Length
     00000000 00000000 ?
index 0b21122fc55c57b5e24fe5d4ea914dfbddbc63dd..9e90bb2c023ce1b73821d2e31cec40c19a125ff1 100644 (file)
@@ -58,8 +58,8 @@ Contents of the .debug_aranges section:
   Length:                   20
   Version:                  2
   Offset into .debug_info:  (0x)?0
-  Pointer Size:             4
-  Segment Size:             0
+  Address size:             4
+  Segment size:             0
 
     Address    Length
     00000000 00000000 ?
index 5a148454685835b1f1082b0350e4693ffdfc73aa..bd0f2acb6d0639d81612c5a941cf4b875224dd3d 100644 (file)
@@ -58,8 +58,8 @@ Contents of the .debug_aranges section:
   Length:                   20
   Version:                  2
   Offset into .debug_info:  (0x)?0
-  Pointer Size:             4
-  Segment Size:             0
+  Address size:             4
+  Segment size:             0
 
     Address    Length
     00000000 00000000 ?
index 6c2cd12a7b75b99c41e756899ffd25911b6c632d..c159868062a14e2e10d30eddee6ae1e04a662a0d 100644 (file)
@@ -58,8 +58,8 @@ Contents of the .debug_aranges section:
   Length:                   20
   Version:                  2
   Offset into .debug_info:  (0x)?0
-  Pointer Size:             4
-  Segment Size:             0
+  Address size:             4
+  Segment size:             0
 
     Address    Length
     00000000 00000000 ?