Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(461)

Unified Diff: src/frames.cc

Issue 1764603003: Handle stack frames differently inside and on the boundary of wasm. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/frames.h ('k') | src/frames-inl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/frames.cc
diff --git a/src/frames.cc b/src/frames.cc
index 643ee69ce8fa3b6ba970d387574683f417707a95..c4653c61e29f03ba0055841d99b0c862fca280ba 100644
--- a/src/frames.cc
+++ b/src/frames.cc
@@ -459,6 +459,10 @@ StackFrame::Type StackFrame::ComputeType(const StackFrameIteratorBase* iterator,
return OPTIMIZED;
case Code::WASM_FUNCTION:
return WASM;
+ case Code::WASM_TO_JS_FUNCTION:
+ return WASM_TO_JS;
+ case Code::JS_TO_WASM_FUNCTION:
+ return JS_TO_WASM;
case Code::BUILTIN:
if (!marker->IsSmi()) {
if (StandardFrame::IsArgumentsAdaptorFrame(state->fp)) {
@@ -707,12 +711,14 @@ void StandardFrame::IterateCompiledFrame(ObjectVisitor* v) const {
// Visit the return address in the callee and incoming arguments.
IteratePc(v, pc_address(), constant_pool_address(), code);
- // Visit the context in stub frame and JavaScript frame.
- // Visit the function in JavaScript frame.
- Object** fixed_base = &Memory::Object_at(
- fp() + StandardFrameConstants::kMarkerOffset);
- Object** fixed_limit = &Memory::Object_at(fp());
- v->VisitPointers(fixed_base, fixed_limit);
+ if (!is_wasm() && !is_wasm_to_js()) {
+ // Visit the context in stub frame and JavaScript frame.
+ // Visit the function in JavaScript frame.
+ Object** fixed_base =
+ &Memory::Object_at(fp() + StandardFrameConstants::kMarkerOffset);
+ Object** fixed_limit = &Memory::Object_at(fp());
+ v->VisitPointers(fixed_base, fixed_limit);
+ }
}
« no previous file with comments | « src/frames.h ('k') | src/frames-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698