aboutsummaryrefslogtreecommitdiff
path: root/gdb/c-lang.c
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@suse.com>2023-01-20 10:18:17 +0100
committerJan Beulich <jbeulich@suse.com>2023-01-20 10:18:17 +0100
commit2d9e089097806867bf6842034bf577e55469f624 (patch)
treef532b3781bcebe95914db72d22ee0dc8ec1b5b17 /gdb/c-lang.c
parentedf772580db29fdddc54deef72d3ddda00c21286 (diff)
downloadgdb-2d9e089097806867bf6842034bf577e55469f624.zip
gdb-2d9e089097806867bf6842034bf577e55469f624.tar.gz
gdb-2d9e089097806867bf6842034bf577e55469f624.tar.bz2
x86: embed register and alike names in disassembler
Register names are (including their nul terminators) on average almost 4 bytes long. Otoh no register name is longer than 8 bytes. Hence even for 32-bit builds using a pointer is only slightly more space efficient than embedding the strings. A level of indirection can be also avoided by embedding the names as an array of 8 characters directly in the arrays, and the number of base relocations in libopcodes.so (or PIE builds of statically linked executables) goes down as well. To amortize for the otherwise reduced folding of string literals by the linker, use att_names_seg[] in place of string literals in append_seg() and OP_ESreg().
Diffstat (limited to 'gdb/c-lang.c')
0 files changed, 0 insertions, 0 deletions