Index: src/compiler/bytecode-graph-builder.cc |
diff --git a/src/compiler/bytecode-graph-builder.cc b/src/compiler/bytecode-graph-builder.cc |
index 47a22df239854b4ef2568736d4c8bcaa87a2a32a..c1ca97c1fe8bb0124007b9d424cf0bb6b6919646 100644 |
--- a/src/compiler/bytecode-graph-builder.cc |
+++ b/src/compiler/bytecode-graph-builder.cc |
@@ -816,7 +816,13 @@ void BytecodeGraphBuilder::VisitNew( |
void BytecodeGraphBuilder::VisitThrow( |
const interpreter::BytecodeArrayIterator& iterator) { |
- UNIMPLEMENTED(); |
+ Node* value = environment()->LookupAccumulator(); |
+ // TODO(mythria): Change to Runtime::kThrow when we have deoptimization |
+ // information support in the interpreter. |
+ NewNode(javascript()->CallRuntime(Runtime::kReThrow, 1), value); |
+ Node* control = NewNode(common()->Throw(), value); |
+ UpdateControlDependencyToLeaveFunction(control); |
+ environment()->BindAccumulator(value); |
} |