Chromium Code Reviews| Index: src/compiler/bytecode-graph-builder.cc |
| diff --git a/src/compiler/bytecode-graph-builder.cc b/src/compiler/bytecode-graph-builder.cc |
| index 5bb208ce94f7e5d8a2550d24cb9d0a1f4268c29b..7dc6dbe580e050729402afeff8d6afd23d2e56ba 100644 |
| --- a/src/compiler/bytecode-graph-builder.cc |
| +++ b/src/compiler/bytecode-graph-builder.cc |
| @@ -5,6 +5,7 @@ |
| #include "src/compiler/bytecode-graph-builder.h" |
| #include "src/compiler/linkage.h" |
| +#include "src/compiler/node-matchers.h" |
| #include "src/compiler/operator-properties.h" |
| #include "src/interpreter/bytecode-array-iterator.h" |
| @@ -643,7 +644,15 @@ void BytecodeGraphBuilder::VisitPopContext( |
| void BytecodeGraphBuilder::VisitCreateClosure( |
| const interpreter::BytecodeArrayIterator& iterator) { |
| - UNIMPLEMENTED(); |
| + Node* accumulator = environment()->LookupAccumulator(); |
| + HeapObjectMatcher shared_info_matcher(accumulator); |
|
Benedikt Meurer
2015/11/22 19:00:53
Why do you need a HeapObjectMatcher at all here? T
oth
2015/11/22 21:43:58
Just to clarify, is question suggesting the Create
|
| + PretenureFlag pretenure = |
| + iterator.GetImmediateOperand(0) ? TENURED : NOT_TENURED; |
| + const Operator* op = javascript()->CreateClosure( |
| + Handle<SharedFunctionInfo>::cast(shared_info_matcher.Value()), pretenure); |
| + Node* closure = NewNode(op); |
| + AddEmptyFrameStateInputs(closure); |
| + environment()->BindAccumulator(closure); |
| } |