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

Unified Diff: src/compiler/bytecode-graph-builder.cc

Issue 1636033002: [interpreter] Fix how 'throw' is translated to TurboFan. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 11 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 | « no previous file | test/cctest/cctest.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/bytecode-graph-builder.cc
diff --git a/src/compiler/bytecode-graph-builder.cc b/src/compiler/bytecode-graph-builder.cc
index ba2247f120c55752d7e484e330f4dff596c85174..dec8194611fdd1b0c4534207928544575764d8e1 100644
--- a/src/compiler/bytecode-graph-builder.cc
+++ b/src/compiler/bytecode-graph-builder.cc
@@ -1361,11 +1361,9 @@ void BytecodeGraphBuilder::VisitThrow(
const interpreter::BytecodeArrayIterator& iterator) {
FrameStateBeforeAndAfter states(this, iterator);
Node* value = environment()->LookupAccumulator();
- // TODO(mythria): Change to Runtime::kThrow when we have deoptimization
- // information support in the interpreter.
- NewNode(javascript()->CallRuntime(Runtime::kReThrow), value);
+ Node* call = NewNode(javascript()->CallRuntime(Runtime::kThrow), value);
+ environment()->RecordAfterState(call, &states);
Node* control = NewNode(common()->Throw(), value);
- environment()->RecordAfterState(control, &states);
UpdateControlDependencyToLeaveFunction(control);
}
@@ -1374,9 +1372,9 @@ void BytecodeGraphBuilder::VisitReThrow(
const interpreter::BytecodeArrayIterator& iterator) {
FrameStateBeforeAndAfter states(this, iterator);
Node* value = environment()->LookupAccumulator();
- NewNode(javascript()->CallRuntime(Runtime::kReThrow), value);
+ Node* call = NewNode(javascript()->CallRuntime(Runtime::kReThrow), value);
+ environment()->RecordAfterState(call, &states);
Node* control = NewNode(common()->Throw(), value);
- environment()->RecordAfterState(control, &states);
UpdateControlDependencyToLeaveFunction(control);
}
« no previous file with comments | « no previous file | test/cctest/cctest.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698