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 5f963770075659cb1939025cf35861bd8235407c..98f4cf1f83e5123bf39a10ed4d08f07cd530006a 100644 |
| --- a/src/compiler/bytecode-graph-builder.cc |
| +++ b/src/compiler/bytecode-graph-builder.cc |
| @@ -704,19 +704,37 @@ void BytecodeGraphBuilder::VisitCreateUnmappedArguments( |
| void BytecodeGraphBuilder::VisitCreateRegExpLiteral( |
| const interpreter::BytecodeArrayIterator& iterator) { |
| - UNIMPLEMENTED(); |
| + Node* closure = GetFunctionClosure(); |
| + const Operator* op = javascript()->CreateLiteralRegExp( |
| + Handle<String>::cast(iterator.GetConstantForIndexOperand(0)), |
| + iterator.GetImmediateOperand(2), iterator.GetIndexOperand(1)); |
|
rmcilroy
2015/12/07 14:33:22
Could you pull out the iterator.GetXXX() to named
mythria
2015/12/07 15:11:18
Done.
|
| + Node* literal = NewNode(op, closure); |
| + AddEmptyFrameStateInputs(literal); |
| + environment()->BindAccumulator(literal); |
| } |
| void BytecodeGraphBuilder::VisitCreateArrayLiteral( |
| const interpreter::BytecodeArrayIterator& iterator) { |
| - UNIMPLEMENTED(); |
| + Node* closure = GetFunctionClosure(); |
| + const Operator* op = javascript()->CreateLiteralArray( |
| + Handle<FixedArray>::cast(iterator.GetConstantForIndexOperand(0)), |
| + iterator.GetImmediateOperand(2), iterator.GetIndexOperand(1)); |
| + Node* literal = NewNode(op, closure); |
| + AddEmptyFrameStateInputs(literal); |
| + environment()->BindAccumulator(literal); |
| } |
| void BytecodeGraphBuilder::VisitCreateObjectLiteral( |
| const interpreter::BytecodeArrayIterator& iterator) { |
| - UNIMPLEMENTED(); |
| + Node* closure = GetFunctionClosure(); |
| + const Operator* op = javascript()->CreateLiteralObject( |
| + Handle<FixedArray>::cast(iterator.GetConstantForIndexOperand(0)), |
| + iterator.GetImmediateOperand(2), iterator.GetIndexOperand(1)); |
| + Node* literal = NewNode(op, closure); |
| + AddEmptyFrameStateInputs(literal); |
| + environment()->BindAccumulator(literal); |
| } |