go-delve / delve

Delve is a debugger for the Go programming language.
MIT License
22.37k stars 2.13k forks source link

refactor: move loadModuleData from runtimeTypeToDIE and expose the apis #3741

Closed jayantxie closed 1 week ago

jayantxie commented 4 weeks ago

@aarzilli Could you help me take a look at these changes to see if they are appropriate? If they are okay, I will add some necessary comments to the codes.

jayantxie commented 4 weeks ago

I will later publish this repository under the organization cloudwego. However, currently, I can only specify it to use my personal forked repository using the go mod replace command. This prevents me from installing it using the "go install" command. Alternatively, could the go-delve/delve repository create a branch for me so that I can directly reference it? And after the features are released and stable for a while, we will merge this PR.

root:~/gopath/src/github.com/jayantxie# go install github.com/jayantxie/goref/cmd/grf@main
go: downloading github.com/jayantxie/goref v0.0.0-20240606095346-cfbff48b5720
go: github.com/jayantxie/goref/cmd/grf@main (in github.com/jayantxie/goref@v0.0.0-20240606095346-cfbff48b5720):
    The go.mod file for the module providing named packages contains one or
    more replace directives. It must not contain directives that would cause
    it to be interpreted differently than if it were the main module.

Do you think it's OK? @aarzilli

jayantxie commented 2 weeks ago

@aarzilli I marked a TODO to read the registers directly instead of reading from Locals, and searching sub objects by bitmap rather than dwarf types. And I rollbacked the API functions you commented. Can you please take a look again?

jayantxie commented 1 week ago

LGTM

Please help to merge it.

aarzilli commented 1 week ago

It will be merged by Derek when he has time.

jayantxie commented 1 week ago

One question.

I don't have access to the repo you listed in the earlier comment so couldn't investigate myself.

I made the temporary repo private, but I will soon open source the code to the github.com/cloudwego/goref repository.