[PATCH] DWARF calculate the number of indexed addresses.

Jeff Law law@redhat.com
Mon May 14 21:09:00 GMT 2018


On 05/14/2018 07:36 AM, Mark Wielaard wrote:
> The length in the .debug_addr unit header was calculated using the number
> of elements in the addr_index_table. This is wrong because the entries in
> the table are refcounted and only those with a refcount > 0 are actually
> put in the index. Add a helper function count_index_addrs to get the
> correct number of addresses in the index.
> 
> gcc/ChangeLog:
> 
> 	* dwarf2out.c (count_index_addrs): New function.
> 	(dwarf2out_finish): Use count_index_addrs to calculate addrs_length.
OK.
jeff



More information about the Gcc-patches mailing list