Golang gdb

From wikinotes
Revision as of 16:16, 26 June 2022 by Will (talk | contribs) (→‎gc)

Instructions for debugging go with gdb.
Instructions vary by compiler

gc

NOTE:

haven't quite gotten this working yet

If compiled with gc (default).

go build -gcflags "-N"
gdb executable

Then it's regular gdb commands

run         # begin running code
layout src  # show place in code
bt          # show backtrace