- 29 11月, 2017 2 次提交
-
-
由 aarzilli 提交于
When creating a stack trace we should switch between the goroutine stack and the system stack (where cgo code is executed) as appropriate to reconstruct the logical stacktrace. Goroutines that are currently executing on the system stack will have the SystemStack flag set, frames of the goroutine stack will have a negative FrameOffset (like always) and frames of the system stack will have a positive FrameOffset (which is actually just the CFA value for the frame). Updates #935
-
由 aarzilli 提交于
Pass CGO_FLAGS='-O0 -g' to go build to disable optimizations when calling the C compiler.
-
- 21 11月, 2017 2 次提交
-
-
由 aarzilli 提交于
Conditional breakpoints with unmet conditions would cause next and step to skip the line. This breakpoint changes the Kind field of proc.Breakpoint from a single value to a bit field, each breakpoint object can represent simultaneously a user breakpoint and one internal breakpoint (of which we have several different kinds). The breakpoint condition for internal breakpoints is stored in the new internalCond field of proc.Breakpoint so that it will not conflict with user specified conditions. The breakpoint setting code is changed to allow overlapping one internal breakpoint on a user breakpoint, or a user breakpoint on an existing internal breakpoint. All other combinations are rejected. The breakpoint clearing code is changed to clear the UserBreakpoint bit and only remove the phisical breakpoint if no other bits are set in the Kind field. ClearInternalBreakpoints does the same thing but clearing all bits that aren't the UserBreakpoint bit. Fixes #844
-
由 aarzilli 提交于
Move some duplicate code, related to breakpoints, that was in both backends into a single place. This is in preparation to solve issue #844 (conditional breakpoints make step and next fail) which will make this common breakpoint code more complicated.
-
- 18 11月, 2017 1 次提交
-
-
由 aarzilli 提交于
Instead of only tracking a few cherrypicked registers in stack.go track all DWARF registers. This is needed for cgo code and for the locationlists emitted by go in 1.10: * The debug_frame sections emitted by C compilers can not be used without tracking all registers * the loclists emitted by go1.10 need all registers of a frame to be interpreted.
-
- 26 9月, 2017 1 次提交
-
-
由 aarzilli 提交于
Make 'next' skip deferred functions unless they are called via a panic. Call to a deferred function through 'return' are predictable, if the user wants to step into them 'step' can be used but without this change there is no way to avoid stepping into them. Implements #956
-
- 21 9月, 2017 1 次提交
-
-
由 aarzilli 提交于
On macOS we can also stop when we receive a signal, propagate this reason upwards to the client. Also clear internal breakpoints after an unrecovered-panic since they can not be reached anymore. Fixes #872
-
- 31 8月, 2017 1 次提交
-
-
由 aarzilli 提交于
Fixes #940
-
- 15 8月, 2017 1 次提交
-
-
由 aarzilli 提交于
Always pick a goroutine that we know will have to be resumed before the program terminates instead of relying on luck. Fixes #803
-
- 02 8月, 2017 5 次提交
-
-
由 aarzilli 提交于
Fixes #106
-
由 aarzilli 提交于
go1.9 no longer needs "linkmode internal" on windows. Fixes #755 Fixes #477 Fixes #631
-
由 aarzilli 提交于
Before go1.9 embedded struct fields had name == "" in runtime and == type name in DWARF. After go1.9 both runtime and DWARF use a simplified version of the type as name. Embedded structs are distinguished from normal fields by setting a flag in the runtime.structfield, for runtime, and by adding a custom attribute in DWARF.
-
由 aarzilli 提交于
-
由 aarzilli 提交于
The compiler a variable 'v' that escapes to the heap with a '&v' entry. Auto dereference those local variables. Fixe #871
-
- 27 7月, 2017 2 次提交
- 19 7月, 2017 1 次提交
-
-
由 Florin Pățan 提交于
-
- 30 6月, 2017 1 次提交
-
-
由 Florin Pățan 提交于
* Fix various issues detected by megacheck I've ran honnef.co/go/tools/cmd/megacheck and fixed a few of the things that came up there. * Cleanup using Gogland
-
- 13 6月, 2017 1 次提交
-
-
由 aarzilli 提交于
Implementing proc.Process.Running in a thread safe way is complicated and nothing actually uses it besides tests, so we are better off rewriting the tests without Running and removing it. In particular: * The call to d.target.Running() in service/debugger/debugger.go (Restart) can never return true because that line executes while holding processMutex and all continue operations are also executed while holding processMutex. * The call to dbp.Running() pkg/proc/native/proc.go (Detach) can never return true, because it's only called from debugger.(*Debugger).detach() which is also always called while holding processMutex. Since some tests are hard to write correctly without Process.Running a simpler interface, Process.NotifyResumed, is introduced. Fixes #830
-
- 26 5月, 2017 1 次提交
-
-
由 aarzilli 提交于
A waitreason string that has invalid length (because the G struct is corrupted or being modified) could cause a crash.
-
- 17 5月, 2017 1 次提交
-
-
由 Alessandro Arzilli 提交于
Before this commit our temp breakpoints only checked that we would stay on the same goroutine. However this isn't enough for recursive functions we must check that we stay on the same goroutine AND on the same stack frame (or, in the case of the StepOut breakpoint, the previous stack frame). This commit: 1. adds a new synthetic variable runtime.frameoff that returns the offset of the current frame from the base of the call stack. This is similar to runtime.curg 2. Changes the condition used for breakpoints on the lines of the current function to check that runtime.frameoff hasn't changed. 3. Changes the condition used for breakpoints on the return address to check that runtime.frameoff corresponds to the previous frame in the stack. 4. All other temporary breakpoints (the step-into breakpoints and defer breakpoints) remain unchanged. Fixes #828
-
- 16 5月, 2017 1 次提交
-
-
由 Alessandro Arzilli 提交于
Debugserver does not work as documented, "--" needs to be specified to pass arguments to the target process (but only if it's an argument that starts with a dash). Fixes #839
-
- 06 5月, 2017 2 次提交
-
-
由 Alessandro Arzilli 提交于
Implements #727
-
由 Alessandro Arzilli 提交于
While implementing the gdbserial backend everything was changed to call Detach to "close" a process so that gdbserial could do its clean up in a single place. However the native implementation of Detach does not actually kill processes we launched. Fixes #821
-
- 05 5月, 2017 1 次提交
-
-
由 Alessandro Arzilli 提交于
debugserver requires a special option to forward the environment to the target. Fixes #818
-
- 29 4月, 2017 1 次提交
-
-
由 Alessandro Arzilli 提交于
* proc/native: remove unused utility methods * proc: turn FindFileLocation, FindFunctionLocation, FirstPCAfterPrologue methods into function
-
- 26 4月, 2017 1 次提交
-
-
由 Alessandro Arzilli 提交于
* proc/eval: fix length calculation for string concatenation * proc/variable: find package variables when the package has a path
-
- 22 4月, 2017 3 次提交
-
-
由 Nathan Bruer 提交于
Go recently introduced proposal tags to their version tags, we are simply allowing delve to handle it appropriately. See: https://github.com/golang/go/commit/0954fdd51e390e209317d4652d7effc15512fd50
-
由 aarzilli 提交于
- moved target.Interface into proc as proc.Process - rename proc.IThread to proc.Thread - replaced interfaces DisassembleInfo, Continuable and EvalScopeConvertible with Process. - removed superfluous Gdbserver prefix from types in the gdbserial backend. - removed superfluous Core prefix from types in the core backend.
-
由 aarzilli 提交于
- move native backend to pkg/proc/native - move gdbserver backend to pkg/proc/gdbserial - move core dumps backend to pkg/proc/core
-
- 19 4月, 2017 4 次提交
- 14 4月, 2017 1 次提交
-
-
由 Alessandro Arzilli 提交于
* proc: Refactor stackIterator to use memoryReadWriter and BinaryInfo * proc: refactor EvalScope to use memoryReadWriter and BinaryInfo * proc: refactor Disassemble to use memoryReadWriter and BinaryInfo
-
- 07 4月, 2017 1 次提交
-
-
由 Alessandro Arzilli 提交于
* proc: refactor BinaryInfo part of proc.Process to own type The data structures and associated code used by proc.Process to implement target.BinaryInfo will also be useful to support a backend for examining core dumps, split this part of proc.Process to a different type. * proc: compile support for all executable formats unconditionally So far we only compiled in support for loading the executable format supported by the host operating system. Once support for core files is introduced it is however useful to support loading in all executable formats, there is no reason why it shouldn't be possible to examine a linux coredump on windows, or viceversa. * proc: bugfix: do not resume threads on detach if killing * Replace BinaryInfo interface with BinInfo() method returning proc.BinaryInfo
-
- 29 3月, 2017 1 次提交
-
-
由 Alessandro Arzilli 提交于
Detach did not work for processes we attach to via PID. Linux: we were only detaching from the main thread, all threads are detached independently Windows: we must resume all threads before detaching. macOS: still broken. Updates #772
-
- 14 3月, 2017 3 次提交
-
-
由 dr2chase 提交于
Stack barriers were removed in Go 1.9, and thus code that expected various stack-barrier-related symbols to exist does not find them. Check for their absence and do not crash when they are missing. Disable stack-barrier-handling test for 1.9 and beyond. Fixes #754.
-
由 Alessandro Arzilli 提交于
One of those goroutines could also conceivably be stopped on line 8.
-
由 Alessandro Arzilli 提交于
The rest of the code uses Detach to "close" a proc.Process, the tests should do the same. Any cleanup that proc.Process needs to do can then be put inside Detach and the tests will run it.
-