aboutsummaryrefslogtreecommitdiff
path: root/gdb/source.c
diff options
context:
space:
mode:
authorMaciej W. Rozycki <macro@embecosm.com>2023-02-10 23:49:19 +0000
committerMaciej W. Rozycki <macro@embecosm.com>2023-02-10 23:49:19 +0000
commit4f82620cc9fd1ef630b6b732a9d939d4e529a07f (patch)
tree4a45e1bb97186da63a81ec40cc0e7db0b3301bdb /gdb/source.c
parentbae19789c0a2d4e88b5b441acebe4d9e1522cd67 (diff)
downloadgdb-4f82620cc9fd1ef630b6b732a9d939d4e529a07f.zip
gdb-4f82620cc9fd1ef630b6b732a9d939d4e529a07f.tar.gz
gdb-4f82620cc9fd1ef630b6b732a9d939d4e529a07f.tar.bz2
GDB: Fix the mess with value byte/bit range types
Consistently use the LONGEST and ULONGEST types for value byte/bit offsets and lengths respectively, avoiding silent truncation for ranges exceeding the 32-bit span, which may cause incorrect matching. Also report a conversion overflow on byte ranges that cannot be expressed in terms of bits with these data types, e.g.: (gdb) print one_hundred[1LL << 58] Integer overflow in data location calculation (gdb) print one_hundred[(-1LL << 58) - 1] Integer overflow in data location calculation (gdb) Previously such accesses would be let through with unpredictable results produced.
Diffstat (limited to 'gdb/source.c')
0 files changed, 0 insertions, 0 deletions