Commit Graph

9 Commits

Author SHA1 Message Date
Alessandro Arzilli
04c4b019f7 api: add FrameOffset to Stackframe (#864)
Other debuggers can be instructed to decorate the stacktrace with the
value of SP. Our SP equivalent is the frame offset, since we can add it
to the Stackframe structure without incurring into added costs we
should, so that frontends can use it if they want.
2017-06-20 10:39:33 -07:00
Alessandro Arzilli
98a4ff7a9f terminal: bugfix: deref of nil SelectedGoroutine switching goroutines (#829)
If CurrentThread isn't running a goroutine SelectedGoroutine can be
nil, do not blindly dereference it.

Fixes #827
2017-05-08 11:16:14 -07:00
Alessandro Arzilli
a843f7944e proc/gdbserial: mozilla rr support (#804)
Implements #727
2017-05-05 15:17:52 -07:00
aarzilli
e4b609bf2b terminal: better list command
- always print a header with the path to the file being displayed
- always evaluate the linespec argument, even if a scope prefix is present

Fixes #711, #713
2017-04-19 10:06:43 -07:00
aarzilli
86a59c52a6 terminal: bugfix: tolerate spurious spaces after command prefixes
Expressions such as:

 frame 0    list
 frame   0   list
 on abreakpoint     print x
 goroutine    1    frame     0     list

should all execute correctly

Fixes #712
2017-04-19 09:58:36 -07:00
aarzilli
c8d9352522 proc: Implement target.Interface for gdbserver backend 2017-04-18 13:25:11 -07:00
aarzilli
1a4b5a05b2 terminal/command_test: improved TestIssue387
The test in question tries to 'next' over a call to wg.Done, this is
not guaranteed to succeed, if the goroutine gets suspended after
wg.Done has notified the waiting group but before returning to
main.dostuff the program could quit before the goroutine is resumed.
2017-02-22 20:39:28 +01:00
aarzilli
92faa95bf9 proc/stack: use BP when FDE is not available
On Windows we can sometimes encounter threads stopped in locations for
which we do not have entries in debug_frame.
These cases seem to be due to calls to Windows API in the go runtime,
we can still produce a (partial) stack trace in this circumstance by
following frame pointers (starting with BP).
We still prefer debug_frame entries when available since go functions
do not have frame pointers before go1.8.
2017-02-22 20:39:28 +01:00
Derek Parker
53f0d24057 Move top-level packages into pkg 2017-02-08 12:17:19 -08:00