aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/.gdbinit17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/.gdbinit b/src/.gdbinit
index b5a974bb38d..21cdca5b2c0 100644
--- a/src/.gdbinit
+++ b/src/.gdbinit
@@ -1303,8 +1303,21 @@ if hasattr(gdb, 'printing'):
1303 1303
1304 # This implementation should work regardless of C compiler, and 1304 # This implementation should work regardless of C compiler, and
1305 # it should not attempt to run any code in the inferior. 1305 # it should not attempt to run any code in the inferior.
1306 EMACS_INT_WIDTH = int(gdb.lookup_symbol("EMACS_INT_WIDTH")[0].value()) 1306
1307 USE_LSB_TAG = int(gdb.lookup_symbol("USE_LSB_TAG")[0].value()) 1307 # If the macros EMACS_INT_WIDTH and USE_LSB_TAG are not in the
1308 # symbol table, guess reasonable defaults.
1309 sym = gdb.lookup_symbol ("EMACS_INT_WIDTH")[0]
1310 if sym:
1311 EMACS_INT_WIDTH = int (sym.value ())
1312 else:
1313 sym = gdb.lookup_symbol ("EMACS_INT")[0]
1314 EMACS_INT_WIDTH = 8 * sym.type.sizeof
1315 sym = gdb.lookup_symbol ("USE_LSB_TAG")[0]
1316 if sym:
1317 USE_LSB_TAG = int (sym.value ())
1318 else:
1319 USE_LSB_TAG = 1
1320
1308 GCTYPEBITS = 3 1321 GCTYPEBITS = 3
1309 VALBITS = EMACS_INT_WIDTH - GCTYPEBITS 1322 VALBITS = EMACS_INT_WIDTH - GCTYPEBITS
1310 Lisp_Int0 = 2 1323 Lisp_Int0 = 2