https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118708

--- Comment #1 from Lewis Hyatt <lhyatt at gcc dot gnu.org> ---
Yeah... I did add the note to the comment "in the case of 32-bit location_t"
but this could certainly be improved. There is also libcpp/location-example.txt
(which the comments refer to) that could be redone for 64-bit as well. The
example in line-map.h could get a more prominent comment like "now that
location_t is 64-bit, all these values are shifted left by 32 bits", or I could
also just overhaul it sometime too.

One reason I didn't update it so far, was I kinda expected there could be more
discussion on how best to make use of all the newly available bits. I tried to
make a minimal extension, but I feel like there a lot of options to consider,
e.g. is "7" the best default range bits now (increased from 5), but also, do we
even still need to bother with LINE_MAP_MAX_LOCATION_WITH_COLUMNS and
LINE_MAP_MAX_LOCATION_WITH_PACKED_RANGES? These were there to help handle it
gracefully when running low on location_t space, but I think now it would take
such an impractically large source file to do that, it might be worth
considering just dropping those concepts and simplifying a lot of code as a
result...

Reply via email to