[Bug debug/47292] Violation of DWARF-3 spec for DW_FORM_strp

2024-04-14 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47292

Andrew Pinski  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |INVALID

--- Comment #2 from Andrew Pinski  ---
case dw_val_class_str:
  form = AT_string_form (a);
  if (form == DW_FORM_strp || form == DW_FORM_line_strp)
size += dwarf_offset_size;


  if (a->dw_attr_val.v.val_str->form == DW_FORM_strp)
dw2_asm_output_offset (dwarf_offset_size,
   a->dw_attr_val.v.val_str->label,
   debug_str_section,
   "%s: \"%s\"", name, AT_string (a));


  if (node->form == DW_FORM_strp)
dw2_asm_output_offset (dwarf_offset_size, node->label,
   debug_str_section, "The macro: \"%s\"",
   ref->info);


>This version of the compiler marks its debug information as dwarf-3
>This version of the compiler is generating 32 bit integers for both 32 and 64 
>bit formats. 

Actually it outputs dwarf3 32bit by default. So this is a misunderstanding
here.

Even if gcc is outting for 64bit, GCC defaults to outputting 32bit dwarf[2-5]. 

GCC 11 (r11-5742-g65312dfc647444) adds an option to change to outputting 64bit
dwarf[2-5] though. (note only powerpc-aix defaults to 64bit dwarf output; all
other targets use 32bit dwarf).

[Bug debug/47292] Violation of DWARF-3 spec for DW_FORM_strp

2011-01-14 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47292

--- Comment #1 from Richard Guenther  2011-01-14 
15:19:29 UTC ---
I think RedHat 4.4.4 is nowhere close to FSF GCC 4.4.x what debug info
is concerned.  Thus I would suggest to report this bug to RedHat
and/or try to reproduce the issue with a stock FSF GCC.