Index: src/wasm/wasm-interpreter.h |
diff --git a/src/wasm/wasm-interpreter.h b/src/wasm/wasm-interpreter.h |
index 7162f22b320770350c7fd5216af5bb09537ce054..f0167d03e7a9c3b76c18f27e7094ed9d8990ef8a 100644 |
--- a/src/wasm/wasm-interpreter.h |
+++ b/src/wasm/wasm-interpreter.h |
@@ -120,6 +120,13 @@ class V8_EXPORT_PRIVATE WasmInterpreter { |
// +------------- Finish -------------> FINISHED |
enum State { STOPPED, RUNNING, PAUSED, FINISHED, TRAPPED }; |
+ // Tells a thread to pause after certain instructions. |
+ enum BreakFlag : uint8_t { |
+ None = 0, |
+ AfterReturn = 1 << 0, |
+ AfterCall = 1 << 1 |
+ }; |
+ |
// Representation of a thread in the interpreter. |
class V8_EXPORT_PRIVATE Thread { |
// Don't instante Threads; they will be allocated as ThreadImpl in the |
@@ -150,6 +157,9 @@ class V8_EXPORT_PRIVATE WasmInterpreter { |
// TODO(wasm): Implement this once we support multiple threads. |
// bool SetBreakpoint(const WasmFunction* function, int pc, bool enabled); |
// bool GetBreakpoint(const WasmFunction* function, int pc); |
+ |
+ void AddBreakFlags(uint8_t flags); |
+ void ClearBreakFlags(); |
}; |
WasmInterpreter(const ModuleBytesEnv& env, AccountingAllocator* allocator); |