[PATCH] dwarf: properly update all_comp_units_without_ranges in stash_comp_unit
Oleg Tolmatcev
oleg.tolmatcev@gmail.com
Thu Sep 18 15:23:34 GMT 2025
Am Do., 18. Sept. 2025 um 16:40 Uhr schrieb Jan Beulich <jbeulich@suse.com>:
> ... why this part of the change? The original code was correct afaics, while
> the new code is correct only as long as what each points to starts out zero-
> initialized (which right now it does, but which we may better not depend upon
> here when it's easy to avoid such a dependency).
I made this change when trying to understand the code. Feel free to drop it.
> > if (each->arange.high == 0)
> > {
> > each->next_unit_without_ranges = file->all_comp_units_without_ranges;
> > - file->all_comp_units_without_ranges = each->next_unit_without_ranges;
> > + file->all_comp_units_without_ranges = each;
> > }
>
> As I assume the patch will need committing on your behalf, I could easily
> reduce it to just this part while committing, provided you agree.
I agree, thank you.
More information about the Binutils
mailing list