On 03/24/2011 01:54 PM, Mark Wielaard wrote:
> + if (abbrev_die_table_in_use == 1)
> +return;
> +
>for (abbrev_id = 1; abbrev_id < abbrev_die_table_in_use; ++abbrev_id)
> {
>dw_die_ref abbrev = abbrev_die_table[abbrev_id];
>
> Still OK?
Yes.
r~
> >/* Terminate the table. */
> > - dw2_asm_output_data (1, 0, NULL);
> > + if (abbrev_die_table_in_use > 1)
> > + dw2_asm_output_data (1, 0, NULL);
>
> I'd prefer this to be handled by
>
> if (abbrev_die_table_in_use == 0)
> return;
>
> at the beginning of the function.
>
> Ok with that ch
On 03/24/2011 09:26 AM, Mark Wielaard wrote:
>/* Terminate the table. */
> - dw2_asm_output_data (1, 0, NULL);
> + if (abbrev_die_table_in_use > 1)
> +dw2_asm_output_data (1, 0, NULL);
I'd prefer this to be handled by
if (abbrev_die_table_in_use == 0)
return;
at the beginning o
Hi,
Detected by the elfutils dwarflint tool.
Example:
$ echo > empty.c
$ gcc -g -c empty.c
$ readelf -x .debug_abbrev empty.o
Hex dump of section '.debug_abbrev':
0x 00 .
Although harmless it might add up if a project has a lot of objects without any