]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
* readelf.c (process_section_headers): Handle linkonce.wi sections.
authorJason Merrill <jason@redhat.com>
Mon, 4 Dec 2000 16:34:44 +0000 (16:34 +0000)
committerJason Merrill <jason@redhat.com>
Mon, 4 Dec 2000 16:34:44 +0000 (16:34 +0000)
        (display_debug_section): Likewise.
        (display_debug_info): Display CU header before bailing.

binutils/ChangeLog
binutils/readelf.c

index 8b21dbc60273921ddcd47c73efddd16348b44f71..9e5904d4cd4190bc40de7b6ef6c2f3cc03d1abfb 100644 (file)
@@ -1,14 +1,20 @@
+2000-12-04  Jason Merrill  <jason@redhat.com>
+
+       * readelf.c (process_section_headers): Handle linkonce.wi sections.
+       (display_debug_section): Likewise.
+       (display_debug_info): Display CU header before bailing.
+
 2000-12-01  Chris Demetriou  <cgd@sibyte.com>
 
-        * readelf.c (get_machine_flags): Recognize MIPS32 ISA in
-        EF_MIPS_ARCH.  Replace use of E_MIPS_MACH_MIPS32 with
-        E_MIPS_MACH_MIPS32_4K and adjust printed CPU name similarly.
+       * readelf.c (get_machine_flags): Recognize MIPS32 ISA in
+       EF_MIPS_ARCH.  Replace use of E_MIPS_MACH_MIPS32 with
+       E_MIPS_MACH_MIPS32_4K and adjust printed CPU name similarly.
 
-        * readelf.c (get_machine_flags): Add cases for E_MIPS_ARCH_5,
-        and E_MIPS_ARCH_64.
+       * readelf.c (get_machine_flags): Add cases for E_MIPS_ARCH_5,
+       and E_MIPS_ARCH_64.
 
-        * readelf.c (get_machine_flags): Add case for
-        E_MIPS_MACH_SB1.
+       * readelf.c (get_machine_flags): Add case for
+       E_MIPS_MACH_SB1.
 
 2000-11-30  Richard Earnshaw  <rearnsha@arm.com>
 
index 110fb848b44cb89f327e5a5138a40f175bf2669f..b173a2b5ed7fb8d9575d1f70e8ee16ffbaeed998 100644 (file)
@@ -2765,6 +2765,10 @@ process_section_headers (file)
              )
            request_dump (i, DEBUG_DUMP);
        }
+      /* linkonce section to be combined with .debug_info at link time.  */
+      else if ((do_debugging || do_debug_info)
+              && strncmp (name, ".gnu.linkonce.wi.", 17) == 0)
+       request_dump (i, DEBUG_DUMP);
       else if (do_debug_frames && strcmp (name, ".eh_frame") == 0)
        request_dump (i, DEBUG_DUMP);
     }
@@ -6323,18 +6327,18 @@ display_debug_info (section, start, file)
       cu_offset = start - section_begin;
       start += compunit.cu_length + sizeof (external->cu_length);
 
+      printf (_("  Compilation Unit @ %lx:\n"), cu_offset);
+      printf (_("   Length:        %ld\n"), compunit.cu_length);
+      printf (_("   Version:       %d\n"), compunit.cu_version);
+      printf (_("   Abbrev Offset: %ld\n"), compunit.cu_abbrev_offset);
+      printf (_("   Pointer Size:  %d\n"), compunit.cu_pointer_size);
+
       if (compunit.cu_version != 2)
        {
          warn (_("Only version 2 DWARF debug information is currently supported.\n"));
          continue;
        }
 
-      printf (_("  Compilation Unit:\n"));
-      printf (_("   Length:        %ld\n"), compunit.cu_length);
-      printf (_("   Version:       %d\n"), compunit.cu_version);
-      printf (_("   Abbrev Offset: %ld\n"), compunit.cu_abbrev_offset);
-      printf (_("   Pointer Size:  %d\n"), compunit.cu_pointer_size);
-
       if (first_abbrev != NULL)
        free_abbrevs ();
 
@@ -7044,6 +7048,8 @@ display_debug_section (section, file)
                  "debug section data");
 
   /* See if we know how to display the contents of this section.  */
+  if (strncmp (name, ".gnu.linkonce.wi.", 17) == 0)
+    name = ".debug_info";  
   for (i = NUM_ELEM (debug_displays); i--;)
     if (strcmp (debug_displays[i].name, name) == 0)
       {