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

Issue 2361333003: Fix crash from turning on DevTools in the middle of catch prediction (Closed)

Created:
4 years, 3 months ago by Dan Ehrenberg
Modified:
4 years, 3 months ago
Reviewers:
gsathya, jgruber
CC:
v8-reviews_googlegroups.com
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

Fix crash from turning on DevTools in the middle of catch prediction If DevTools is turned on in the middle of doing some things with async functions, then more items may be popped from the Promise stack than were pushed to it. In this sort of case, it's OK to have a catch misprediction, but a crash is unacceptable. This patch defensively handles this edge case where the Promise stack is unexpectedly empty for that reason. BUG=v8:5167 Committed: https://crrev.com/cd049c2c761739590e42dd3e4213a88959163b8d Cr-Commit-Position: refs/heads/master@{#39705}

Patch Set 1 #

Patch Set 2 : Format #

Total comments: 4

Patch Set 3 : Simplify code in ASYNC_AWAIT case of GetPromiseOnStackOnThrow #

Unified diffs Side-by-side diffs Delta from patch set Stats (+25 lines, -1 line) Patch
M src/isolate.cc View 1 2 1 chunk +4 lines, -1 line 0 comments Download
M test/mjsunit/harmony/async-debug-caught-exception.js View 1 chunk +21 lines, -0 lines 0 comments Download

Messages

Total messages: 18 (11 generated)
Dan Ehrenberg
4 years, 3 months ago (2016-09-24 00:55:43 UTC) #4
gsathya
https://codereview.chromium.org/2361333003/diff/20001/src/isolate.cc File src/isolate.cc (right): https://codereview.chromium.org/2361333003/diff/20001/src/isolate.cc#newcode1763 src/isolate.cc:1763: if (promise_on_stack) retval = promise_on_stack->promise(); Can you not return ...
4 years, 3 months ago (2016-09-24 01:14:09 UTC) #5
Dan Ehrenberg
https://codereview.chromium.org/2361333003/diff/20001/src/isolate.cc File src/isolate.cc (right): https://codereview.chromium.org/2361333003/diff/20001/src/isolate.cc#newcode1763 src/isolate.cc:1763: if (promise_on_stack) retval = promise_on_stack->promise(); On 2016/09/24 at 01:14:09, ...
4 years, 3 months ago (2016-09-24 03:08:20 UTC) #12
gsathya
lgtm
4 years, 3 months ago (2016-09-24 03:28:00 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2361333003/40001
4 years, 3 months ago (2016-09-24 03:28:39 UTC) #15
commit-bot: I haz the power
Committed patchset #3 (id:40001)
4 years, 3 months ago (2016-09-24 03:30:59 UTC) #16
commit-bot: I haz the power
4 years, 3 months ago (2016-09-24 03:31:25 UTC) #18
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/cd049c2c761739590e42dd3e4213a88959163b8d
Cr-Commit-Position: refs/heads/master@{#39705}

Powered by Google App Engine
This is Rietveld 408576698