This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] S12Z: Set eh_addr_size to 4


---
 binutils/objdump.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/binutils/objdump.c b/binutils/objdump.c
index f468fcdb59..d3ab2e4cd1 100644
--- a/binutils/objdump.c
+++ b/binutils/objdump.c
@@ -2711,6 +2711,11 @@ dump_dwarf (bfd *abfd)
 
   eh_addr_size = bfd_arch_bits_per_address (abfd) / 8;
 
+  /* S12Z has a 24 bit address space.  But the only known
+     producer of dwarf_info encodes addresses into 32 bits. */
+  if (bfd_get_arch (abfd) == bfd_arch_s12z)
+    eh_addr_size = 4;
+
   if (bfd_big_endian (abfd))
     byte_get = byte_get_big_endian;
   else if (bfd_little_endian (abfd))
-- 
2.11.0


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]