- 11 3月, 2020 1 次提交
-
-
由 chainhelen 提交于
Implement debugging function for 386 on linux with reference to AMD64. There are a few remaining problems that need to be solved in another time. 1. The stacktrace of cgo are not exactly as expected. 2. Not implement `core` for now. 3. Not implement `call` for now. Can't not find `runtime·debugCallV1` or similar function in $GOROOT/src/runtime/asm_386.s. Update #20
-
- 10 3月, 2020 3 次提交
-
-
由 Alessandro Arzilli 提交于
* proc/native/linux: only set breakpoints on threads that receive SIGTRAP * proc/native/linux: do not call (*Thread).Stopped inside (*Process).stop (*Thread).Stopped is slow because it needs to open, read and parse a file in /proc, we don't actually need to do that, we can just rely on the value of Thread.os.running. Benchmark before: BenchmarkConditionalBreakpoints-4 1 12476166303 ns/op Benchmark after: BenchmarkConditionalBreakpoints-4 1 10403533675 ns/op Conditional breakpoint evaluation: 1.24ms -> 1ms Updates #1549
-
由 polinasok 提交于
* logflags: Add pid to server-listening-at message * Address review comments: use logger Co-authored-by: NPolina Sokolova <polinasok@users.noreply.github.com>
-
由 aarzilli 提交于
There are too many commands, for clarity they should be divided into categories when printing and generating documentation.
-
- 06 3月, 2020 1 次提交
-
-
由 Derek Parker 提交于
-
- 05 3月, 2020 1 次提交
-
-
由 polinasok 提交于
* service/dap: Add support for debug and test modes * Address code review comments * Remove //dap comment * OptFlags() => optfalgs() * If mode => switch mode
-
- 04 3月, 2020 1 次提交
-
-
由 aarzilli 提交于
-
- 03 3月, 2020 1 次提交
-
-
由 a 提交于
Disables async preemption on macOS Fixes #1905
-
- 01 3月, 2020 3 次提交
-
-
由 Derek Parker 提交于
Use strings.Builder and tabwriter to format the output of the examine memory command instead of doing direct string manipulation and allocating.
-
由 Derek Parker 提交于
This also removes Go 1.11 from the test matrix. Now that 1.14 has been released, as always it should be included in the test matrix.
-
由 Josh Stone 提交于
This change adds `ProcessVmRead` and `ProcessVmWrite` wrappers around the syscalls `process_vm_readv` and `process_vm_writev`, available since Linux 3.2. These follow the same permission model as `ptrace`, but they don't actually require being attached, which means they can be called directly from any thread in the debugger. They also use `iovec` to write entire blocks at once, rather than having to peek/poke each `uintptr`. These wrappers are used in `Thread.ReadMemory` and `WriteMemory`, still falling back to `ptrace` if that fails for any reason. Notably, `process_vm_writev` respects memory protection, so it can't modify read-only memory like `ptrace`. This frequently occurs when writing breakpoints in read-only `.text`, so to avoid a lot of wasted `EFAULT` calls, we only try `process_vm_writev` for larger writes.
-
- 29 2月, 2020 2 次提交
-
-
由 chainhelen 提交于
-
由 polinasok 提交于
-
- 27 2月, 2020 3 次提交
-
-
由 chainhelen 提交于
1. Don't use intelligent '#' in fmt of go because it is not always satisfying for diffrent version of golang. Always keep one leading zero for octal and one leading '0x' for hex manually. Then keep alignment for every byte. 2. Always keep addr alignment when the lens of two adjacent address are different. Update #1814.
-
由 Eli Bendersky 提交于
Using a stop channel to signal clean shutdown to the server's goroutines. Also updates the tests to trigger disconnectChan. This helps avoid spurious error logs when the client disconnects, when Ctrl+C is pressed, etc.
-
由 Alessandro Arzilli 提交于
Go 1.14 has more fake file names, apparently (also go fmt).
-
- 26 2月, 2020 3 次提交
-
-
由 chainhelen 提交于
-
由 Eli Bendersky 提交于
* Panic guard for DAP request handling * Use GetSeq * Re-vendor new version of go-dap * Remove comment * Update error message * Reuse er.Message in Format
-
由 Alessandro Arzilli 提交于
Fixes a bug introduced by the logical breakpoint change, where creating the same breakpoint twice deletes the breakpoint.
-
- 25 2月, 2020 6 次提交
-
-
由 Alessandro Arzilli 提交于
Adds an optional scope prefix to the `regs` command which allows printing registers for any stack frame (as long as they were somehow saved). Issue #1838 is not yet to be closed since we are still not recovering the registers of a segfaulting frame. Updates #1838
-
由 Alessandro Arzilli 提交于
-
由 Alessandro Arzilli 提交于
As we rearrange the code and the Go compiler changes the error message returned by the compiler on unsupported architectures will change too, making it un-googlable. Since the error message tends to be rather obscure too this regularly confuses newbies. This is an effort to make the error message for unsupported GOOS/GOARCH combinations the same across all unsupported combinations and to make it more user friendly. Directories containing Go source code are supposed to contain a single package. This property happens to be checked by cmd/go itself so it will happen even before the syntax is fully checked and therefore has a high probability of being the first (and only) error message being print. Here we take advantage of this by adding to the pkg/proc/native directory a file with a bad package line that only gets compiled in on unsupported GOOS/GOARCH combinations. At present the error message for compiling Delve on unsupported systems will be: service/debugger/debugger.go:21:2: found packages native (proc.go) and your_operating_system_and_architecture_combination_is_not_supported_by_delve (support_sentinel.go) in $PATH_TO_DELVE/pkg/proc/native
-
由 Eli Bendersky 提交于
* Remove hardcoded tests * Cleanup - consistent naming, simplify some code, remove unused func * Address review comments * Add Seq checks back * Address more review comments * Remove hardcoded tests * Cleanup - consistent naming, simplify some code, remove unused func * Address review comments * Add Seq checks back * Address more review comments * Make more consistent * More consistency * Simplify Except* methods with a helper Mark t.Helper() where appropriate
-
由 chainhelen 提交于
Avoid always showing `no G executing on thread 0` when ErrNoGoroutine on g0 stack in GetG.
-
由 Koichi Shiraishi 提交于
macOS hasn't /usr/include/sys/types.h header with Canalina or later. switch types.h path to CommandLineTools if kernel minor version up to 15 or later.
-
- 22 2月, 2020 2 次提交
-
-
由 Hyang-Ah Hana Kim 提交于
- Move package doc comments so they are recognized as package doc. - Use t.Helper when appropriate.
-
由 Klemens Morgenstern 提交于
* Fixed DirIdx (index starts at one) I am using the elf to load C++ based elf and there the index starts at one and not zero, hence the minor fix. * Added test * Added proper test for c-generated elf & replaced index offset by adding build dir * Changed other IncludeDir test * Format fix & replace print with actual test * Format fixes @derekparker requested.
-
- 21 2月, 2020 1 次提交
-
-
由 Alessandro Arzilli 提交于
Go 1.8 has been out of date for a while and the code to support it is potentially dangerous if a future version of Go removes the runtime types from debug_info and also changes their representation.
-
- 20 2月, 2020 2 次提交
-
-
由 Derek Parker 提交于
Removes the restriction that the DWARF type for the receiver of a method must be a TypeDef. This seems reasonable in practice, but it turns out Go DWARF does not consider ``` type X int ``` to be a typedef. This patch also allows for calling a method where the receiver is not used or passed in, such as: ``` func (_ X) Method() { println("why") } ```
-
由 chainhelen 提交于
Avoid panic if start addr is greater than end addr when disasm.
-
- 19 2月, 2020 1 次提交
-
-
由 Sylvain Rabot 提交于
Signed-off-by: NSylvain Rabot <s.rabot@lectra.com>
-
- 18 2月, 2020 2 次提交
-
-
由 ossdev07 提交于
* proc/native: optimize native.status through buffering (#1865) Benchmark before: BenchmarkConditionalBreakpoints-4 1 15649407130 ns/op Benchmark after: BenchmarkConditionalBreakpoints-4 1 14586710018 ns/op Conditional breakpoint evaluation 1.56ms -> 1.45ms Updates #1549 * proc/core: Review Comments Incorporated Signed-off-by: Nossdev07 <ossdev@puresoftware.com> Co-authored-by: NAlessandro Arzilli <alessandro.arzilli@gmail.com>
-
由 Alessandro Arzilli 提交于
runtime.g is a large and growing struct, we only need a few fields. Instead of using loadValue to load the full contents of g, cache its memory and then only load the fields we care about. Benchmark before: BenchmarkConditionalBreakpoints-4 1 14586710018 ns/op Benchmark after: BenchmarkConditionalBreakpoints-4 1 12476166303 ns/op Conditional breakpoint evaluation: 1.45ms -> 1.24ms Updates #1549
-
- 16 2月, 2020 2 次提交
-
-
由 Alessandro Arzilli 提交于
Benchmark before: BenchmarkConditionalBreakpoints-4 1 15649407130 ns/op Benchmark after: BenchmarkConditionalBreakpoints-4 1 14586710018 ns/op Conditional breakpoint evaluation 1.56ms -> 1.45ms Updates #1549
-
由 polinasok 提交于
* Initial implementation for 'dlv dap' * Fix Travis and AppVeyor failures * Address review comments * Address review comments * Regenrate documentation * Replace dap server printfs with log.Error * Update 'dap log' * Fix typos * Revert logflags changes that got mixed in by accident
-
- 15 2月, 2020 1 次提交
-
-
由 Alessandro Arzilli 提交于
Logged errors should be visible even if the corresponding flag was not selected.
-
- 14 2月, 2020 3 次提交
-
-
由 Derek Parker 提交于
Instead of reloading the registers for every thread every time the process executes, reload the registers on demand for individual threads and memoize the result.
-
由 chainhelen 提交于
According to #1800 #1584 #1038, `dlv` should enable the user to dive into memory. User can print binary data in specific memory address range. But not support for sepecific variable name or structures temporarily.(Because I have no idea that modify `print` command.) Close #1584.
-
由 Alessandro Arzilli 提交于
The stacktrace code occasionally needs the value of g.m.g0.sched.sp to switch stacks. Since this is only needed rarely and calling parseG is relatively expensive we should delay doing it until we know it will be needed. Benchmark before: BenchmarkConditionalBreakpoints-4 1 17326345671 ns/op Benchmark after: BenchmarkConditionalBreakpoints-4 1 15649407130 ns/op Reduces conditional breakpoint latency from 1.7ms to 1.56ms. Updates #1549
-
- 13 2月, 2020 1 次提交
-
-
由 Alessandro Arzilli 提交于
A significant amount of time is spent generating the string representation for the proc.Registers object of each thread, since this field is rarely used (only when the Registers API is called) it should be generated on demand. Also by changing the internal representation of proc.Register to be closer to that of op.DwarfRegister it will help us implement #1838 (when Delve will need to be able to display the registers of an internal frame, which we currently represent using op.DwarfRegister objects). Benchmark before: BenchmarkConditionalBreakpoints-4 1 22292554301 ns/op Benchmark after: BenchmarkConditionalBreakpoints-4 1 17326345671 ns/op Reduces conditional breakpoint latency from 2.2ms to 1.7ms. Updates #1549, #1838
-