[Lldb-commits] [PATCH] D78801: [LLDB] Add class ProcessWasm for WebAssembly debugging

Paolo Severini via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed Apr 29 11:49:14 PDT 2020


paolosev added a comment.

Also, to eliminate `qWasmCallStack` we could maybe add the call stack (a list of PCs) to the stop packet. The format of a stop packet is:

  T AA n1:r1;n2:r2;…
  
  The program received signal number AA (a two-digit hexadecimal number). [...] Each ‘n:r’ pair is interpreted as follows:
  If n is a hexadecimal number, it is a register number, and the corresponding r gives that register’s value. [...]
  If n is ‘thread’, then r is the thread-id of the stopped thread, as specified in thread-id syntax.
  If n is ‘core’, then r is the hexadecimal number of the core on which the stop event was detected.
  Otherwise, GDB should ignore this ‘n:r’ pair and go on to the next; this allows us to extend the protocol in the future.

So adding a 'stack:xxxxx...xxx' pair should be possible. If we reuse `m`, `M` in place of qWasmLocal, qWasmGlobal and qWasmStackValue and add generic qMemSpaceRead/qMemSpaceWrite for the memory, then there would be no new Wasm-specific command to add to the protocol.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D78801/new/

https://reviews.llvm.org/D78801





More information about the lldb-commits mailing list