Index: src/frames.cc |
diff --git a/src/frames.cc b/src/frames.cc |
index 45d26a161abe8b9f53a52af976f830b2cc7a2d95..a7b5c3ef839b713a0d0065826dceda4b3cc29288 100644 |
--- a/src/frames.cc |
+++ b/src/frames.cc |
@@ -1752,7 +1752,7 @@ void WasmInterpreterEntryFrame::Iterate(ObjectVisitor* v) const { |
void WasmInterpreterEntryFrame::Print(StringStream* accumulator, PrintMode mode, |
int index) const { |
PrintIndex(accumulator, mode, index); |
- accumulator->Add("WASM TO INTERPRETER ["); |
+ accumulator->Add("WASM INTERPRETER ENTRY ["); |
Script* script = this->script(); |
accumulator->PrintName(script->name()); |
accumulator->Add("]"); |
@@ -1761,8 +1761,17 @@ void WasmInterpreterEntryFrame::Print(StringStream* accumulator, PrintMode mode, |
void WasmInterpreterEntryFrame::Summarize(List<FrameSummary>* functions, |
FrameSummary::Mode mode) const { |
- // TODO(clemensh): Implement this. |
- UNIMPLEMENTED(); |
+ Handle<WasmInstanceObject> instance(wasm_instance(), isolate()); |
+ Handle<WasmDebugInfo> debug_info = |
+ WasmInstanceObject::GetOrCreateDebugInfo(instance); |
+ std::vector<std::pair<uint32_t, int>> interpreted_stack = |
+ WasmDebugInfo::GetInterpretedStack(debug_info, fp()); |
+ |
+ for (auto& e : interpreted_stack) { |
+ FrameSummary::WasmInterpretedFrameSummary summary(isolate(), instance, |
+ e.first, e.second); |
+ functions->Add(summary); |
+ } |
} |
Code* WasmInterpreterEntryFrame::unchecked_code() const { |