summaryrefslogtreecommitdiff
path: root/util/gdbinit.tmpl
diff options
context:
space:
mode:
authorFreya Murphy <freya@freyacat.org>2025-03-25 18:00:51 -0400
committerFreya Murphy <freya@freyacat.org>2025-03-25 18:00:51 -0400
commit3152b2ae078f83145774d2dbfaf6f471b8b766e8 (patch)
treec730760860824a452daaf4a04f9fd8c738a63929 /util/gdbinit.tmpl
parentremove legacy bullshit (diff)
downloadcomus-3152b2ae078f83145774d2dbfaf6f471b8b766e8.tar.gz
comus-3152b2ae078f83145774d2dbfaf6f471b8b766e8.tar.bz2
comus-3152b2ae078f83145774d2dbfaf6f471b8b766e8.zip
more qemu opts and gdb
Diffstat (limited to 'util/gdbinit.tmpl')
-rw-r--r--util/gdbinit.tmpl31
1 files changed, 0 insertions, 31 deletions
diff --git a/util/gdbinit.tmpl b/util/gdbinit.tmpl
deleted file mode 100644
index d9a981d..0000000
--- a/util/gdbinit.tmpl
+++ /dev/null
@@ -1,31 +0,0 @@
-# adapted from the xv6 .gdbinit.tmpl file
-set $lastcs = -1
-
-define hook-stop
- # There doesn't seem to be a good way to detect if we're in 16- or
- # 32-bit mode, but we always run with CS == 8 in 32-bit mode.
- if $cs == 8 || $cs == 27
- if $lastcs != 8 && $lastcs != 27
- set architecture i386
- end
- x/i $pc
- else
- if $lastcs == -1 || $lastcs == 8 || $lastcs == 27
- set architecture i8086
- end
- # Translate the segment:offset into a physical address
- printf "[%4x:%4x] ", $cs, $eip
- x/i $cs*16+$eip
- end
- set $lastcs = $cs
-end
-
-echo + target remote localhost:1234\n
-target remote localhost:1234
-
-# If this fails, it's probably because your GDB doesn't support ELF.
-# Look at the tools page at
-# http://pdos.csail.mit.edu/6.828/2009/tools.html
-# for instructions on building GDB with ELF support.
-echo + symbol-file build/kernel/kernel\n
-symbol-file build/kernel/kernel