Page MenuHomePhabricator

Implement basic DidAttach for DynamicLoaderWindowsDYLD for use with ds2
ClosedPublic

Authored by lanza on Dec 6 2018, 12:46 PM.

Details

Summary

Windows lldb debugging currently uses a process plugin to handle
launching and attaching to a process. Launching a process via a debug
server (e.g. ds2) and attaching to it with gdb-remote port currently
doesn't communicate address information of the executable properly.

Implement DidAttach for the windows DynamicLoader plugin which allow us to
obtain the proepr address information.

Event Timeline

lanza created this revision.Dec 6 2018, 12:46 PM
This revision was not accepted when it landed; it landed in state Needs Review.Dec 6 2018, 1:16 PM
This revision was automatically updated to reflect the committed changes.

You would recommend getting a post-commit review from @labath or @zturner

I am afraid I know know much about windows, or ds2. The thing I noticed is that this only seems to set the address of the main executable. Don't you also need to set the load address of loaded shared libraries (if any)?

lanza added a comment.Dec 7 2018, 4:55 PM

@zturner and I spoke about it before landing

@labath - correct. Dll loading needs handled. This was to upstream hello world functionality without DLLs. I need to figure out where and when to synchronize between ds2 and lldb for the LOAD_DLL_DEBUG_EVENT. I'll probably get to this early next week.