https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69650
--- Comment #14 from Manuel López-Ibáñez <manu at gcc dot gnu.org> --- (In reply to rguent...@suse.de from comment #12) > > This is an invalid linemarker. libcpp should ignore it completely and > > behave as > > if it was not present. It seems it is not doing that for some reason and > > that > > is messing up the line-table. > > Sure, but I don't see that 1048539 line number anywhere so it feels like > sth is used uninitialized? This was thoroughly analyzed by David above. The invalid linemarker causes an invalid LC_LEAVE which then triggers an invalid line-number calculation. Somehow, the code for handling the invalid linemarker is doing the wrong thing. Perhaps this: to_line = SOURCE_LINE (from, from[1].start_location); should be to_line = SOURCE_LINE (from, from->start_location); But I don't understand what the following comment means (love those cryptic comments in GCC!) /* A TO_FILE of NULL is special - we use the natural values. */ if (error || to_file == NULL) { to_file = ORDINARY_MAP_FILE_NAME (from); to_line = SOURCE_LINE (from, from[1].start_location); sysp = ORDINARY_MAP_IN_SYSTEM_HEADER_P (from); } so it may be trying to do something else besides error-handling.