| Index: src/wasm/wasm-objects.cc
|
| diff --git a/src/wasm/wasm-objects.cc b/src/wasm/wasm-objects.cc
|
| index 4779d88d678b500a6b55fa291fde79be8597da77..af6a446dcc896cea32364f9e5e4fefc384e329c1 100644
|
| --- a/src/wasm/wasm-objects.cc
|
| +++ b/src/wasm/wasm-objects.cc
|
| @@ -1119,6 +1119,26 @@ bool WasmCompiledModule::SetBreakPoint(
|
| return true;
|
| }
|
|
|
| +BreakLocation WasmCompiledModule::GetBreakLocation(int position) {
|
| + DCHECK_LE(0, position);
|
| + DCHECK_GT(module_bytes()->length(), position);
|
| + uint8_t opcode = module_bytes()->GetChars()[position];
|
| + DebugBreakType type;
|
| + switch (opcode) {
|
| + case kExprReturn:
|
| + type = DEBUG_BREAK_SLOT_AT_RETURN;
|
| + break;
|
| + case kExprCallFunction:
|
| + case kExprCallIndirect:
|
| + type = DEBUG_BREAK_SLOT_AT_CALL;
|
| + break;
|
| + default:
|
| + type = DEBUG_BREAK_SLOT;
|
| + break;
|
| + }
|
| + return BreakLocation(Handle<AbstractCode>::null(), type, position, position);
|
| +}
|
| +
|
| MaybeHandle<FixedArray> WasmCompiledModule::CheckBreakPoints(
|
| const BreakLocation& location) {
|
| Isolate* isolate = GetIsolate();
|
|
|