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

Paolo Severini via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Apr 24 02:06:36 PDT 2020


paolosev marked 2 inline comments as done.
paolosev added a comment.

What is the best way to test classes WasmProcessGDBRemote and UnwindWasm?



================
Comment at: lldb/source/Plugins/Process/wasm/ProcessWasm.cpp:92
+                                        size_t buffer_size, size_t &size) {
+  // TODO(paolosev): Implement in GDBRemoteComunicationClient
+  return false;
----------------
This will be implemented as:
```
  return GetGDBRemote().GetWasmLocal(frame_index, index, buf, buffer_size, size);
```
as soon as `GetWasmLocal` can be added to GDBRemoteCommunicationClient.


================
Comment at: lldb/source/Plugins/Process/wasm/UnwindWasm.cpp:34-35
+
+    IWasmProcess *wasm_process =
+        static_cast<WasmProcessGDBRemote *>(GetThread().GetProcess().get());
+    if (wasm_process)
----------------
This cast works but it is ugly. Is there a better coding pattern I could use here?


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