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

Unified Diff: src/frames.cc

Issue 1895603002: [esnext] prototype runtime implementation for async functions (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@AsyncFunction
Patch Set: fix remaining brokenness in throw resuming Created 4 years, 8 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/factory.cc ('k') | src/full-codegen/x64/full-codegen-x64.cc » ('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 4f2f0086a794243001b82db0f5a41bec354ebbd5..630d8f96e3093af7bb8fb11d3422ce814d035e61 100644
--- a/src/frames.cc
+++ b/src/frames.cc
@@ -863,6 +863,14 @@ void JavaScriptFrame::GetFunctions(List<JSFunction*>* functions) const {
void JavaScriptFrame::Summarize(List<FrameSummary>* functions) const {
DCHECK(functions->length() == 0);
Code* code = LookupCode();
+
+ // TODO(caitp): these builtins cause crashes here --- that's not good!
+ // Should probably be a better way to keep functions from being included in
+ // stack trace.
+ if (code == *function()->GetIsolate()->builtins()->AsyncFunctionNext() ||
caitp (gmail) 2016/04/16 20:09:30 other than the off-by-one bug mentioned and fixed
+ code == *function()->GetIsolate()->builtins()->AsyncFunctionThrow())
+ return;
+
int offset = static_cast<int>(pc() - code->instruction_start());
AbstractCode* abstract_code = AbstractCode::cast(code);
FrameSummary summary(receiver(), function(), abstract_code, offset,
« no previous file with comments | « src/factory.cc ('k') | src/full-codegen/x64/full-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698