[Bug symtab/33247] New: Address ranges validation in gdb-index should be more strict

aesc.trofimow at gmail dot com sourceware-bugzilla@sourceware.org
Sun Aug 3 17:00:23 GMT 2025


https://sourceware.org/bugzilla/show_bug.cgi?id=33247

            Bug ID: 33247
           Summary: Address ranges validation in gdb-index should be more
                    strict
           Product: gdb
           Version: HEAD
            Status: UNCONFIRMED
          Severity: minor
          Priority: P2
         Component: symtab
          Assignee: unassigned at sourceware dot org
          Reporter: aesc.trofimow at gmail dot com
  Target Milestone: ---

Hi!

As a follow-up on 24a550149d4e29a9285b420d27bc0b2b487b802a,
shouldn't the condition in address range validation be lo _>=_ hi,
instead of just lo _>_ hi?


I'm seeing LLVM BOLT sometimes generating address ranges like this
Low/High address = [0x0, 0x0) (Size: 0x0), CU id = 326
, which looks like a BOLT bug to me (llvm issue 151857), but still
makes gdb _spam_ errors like these:

warning: (Error: pc 0x7ffff7fe7258 in address map, but not in symtab.)
warning: (Internal error: pc 0x7fffffffe348 in read in CU, but not in symtab.)

AFAIU the reason for these errors is a wrapping underflow for the 'hi' address,
which leads to all the address-space range suddenly being covered by something
unrelated in addrmap, and changing the condition to GTE does indeed fixes the
error spam.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Gdb-prs mailing list