JDevlieghere wrote:

Hey @alexcrichton and @fitzgen, thanks for chiming in here! The idea to 
implement a DAP server to support interpreted languages is an interesting idea. 
As someone who's been involved with 
[lldb-dap](https://github.com/llvm/llvm-project/tree/main/lldb/tools/lldb-dap) 
I have some experience in that space. 

My immediate question about how you're planning on supporting that was answered 
by the "Debug Adapter Components" section. The following sentence stood out to 
me:

> [W]e propose using the component model to design an interface for a debug 
> adapter. A debug adapter will import a private interface that gives it 
> low-level access to the underlying Wasm debuggee, and will export a 
> higher-level interface that the debugger will interact with and query. 

This is basically describing the GDB remote protocol. In the world of native 
debugging, it's the standard for talking to a debugger like lldb and gdb. I 
definitely think it's something worth considering, and it sounds like Alex 
seems to be saying something similar.

> I'm not personally aware of other runtimes that want to mirror what WAMR is 
> doing here. The current plan for Wasmtime won't include mirroring the support 
> natively, but that's not to say Wasmtime's plan is set in stone and not 
> possible to change either.

The V8 JavaScript engine is another example, and in the context of Swift, 
[WasmKit](https://github.com/swiftwasm/WasmKit/issues/141) is interested in it 
as well.

> Small clarification / additional context as the Wasmtime-focused team I am on 
> just finished some planning: some folks (@cfallin and others) have actually 
> started working on the implementation of parts of that debugging RFC already, 
> and while they haven't yet started on the debug adapter protocol 
> implementation that the lldb frontend (or others) could attach to, that is 
> the next big milestone after the current one. The plan is to begin the debug 
> adapter protocol implementation work roughly around the beginning of Q4.

When you talk about LLDB as a "client", I assume you mean the "debug adapater 
component" rather than the "debug adapter protocol"? 

https://github.com/llvm/llvm-project/pull/150143
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to