Index: src/interpreter/interpreter.cc |
diff --git a/src/interpreter/interpreter.cc b/src/interpreter/interpreter.cc |
index a6e9317e0f03e2d8a3175314f1b258d77be8bae4..170576402c027e4e39545dfd0eec0b24c97cb6e8 100644 |
--- a/src/interpreter/interpreter.cc |
+++ b/src/interpreter/interpreter.cc |
@@ -721,23 +721,6 @@ void Interpreter::DoJumpIfFalseConstant( |
} |
-void Interpreter::DoCreateLiteral(Runtime::FunctionId function_id, |
- compiler::InterpreterAssembler* assembler) { |
- Node* constant_elements = __ GetAccumulator(); |
- Node* literal_index_raw = __ BytecodeOperandIdx8(0); |
- Node* literal_index = __ SmiTag(literal_index_raw); |
- Node* flags_raw = __ BytecodeOperandImm8(1); |
- Node* flags = __ SmiTag(flags_raw); |
- Node* closure = __ LoadRegister(Register::function_closure()); |
- Node* literals_array = |
- __ LoadObjectField(closure, JSFunction::kLiteralsOffset); |
- Node* result = __ CallRuntime(function_id, literals_array, literal_index, |
- constant_elements, flags); |
- __ SetAccumulator(result); |
- __ Dispatch(); |
-} |
- |
- |
// JumpIfToBooleanTrue <imm8> |
// |
// Jump by number of bytes represented by an immediate operand if the object |
@@ -804,6 +787,44 @@ void Interpreter::DoJumpIfToBooleanFalseConstant( |
} |
+// CreateRegExpLiteral <idx> <flags_reg> |
+// |
+// Creates a regular expression literal for literal index <idx> with flags held |
+// in <flags_reg> and the pattern in the accumulator. |
+void Interpreter::DoCreateRegExpLiteral( |
+ compiler::InterpreterAssembler* assembler) { |
+ Node* pattern = __ GetAccumulator(); |
+ Node* literal_index_raw = __ BytecodeOperandIdx8(0); |
+ Node* literal_index = __ SmiTag(literal_index_raw); |
+ Node* flags_reg = __ BytecodeOperandReg8(1); |
+ Node* flags = __ LoadRegister(flags_reg); |
+ Node* closure = __ LoadRegister(Register::function_closure()); |
+ Node* literals_array = |
+ __ LoadObjectField(closure, JSFunction::kLiteralsOffset); |
+ Node* result = __ CallRuntime(Runtime::kMaterializeRegExpLiteral, |
+ literals_array, literal_index, pattern, flags); |
+ __ SetAccumulator(result); |
+ __ Dispatch(); |
+} |
+ |
+ |
+void Interpreter::DoCreateLiteral(Runtime::FunctionId function_id, |
+ compiler::InterpreterAssembler* assembler) { |
+ Node* constant_elements = __ GetAccumulator(); |
+ Node* literal_index_raw = __ BytecodeOperandIdx8(0); |
+ Node* literal_index = __ SmiTag(literal_index_raw); |
+ Node* flags_raw = __ BytecodeOperandImm8(1); |
+ Node* flags = __ SmiTag(flags_raw); |
+ Node* closure = __ LoadRegister(Register::function_closure()); |
+ Node* literals_array = |
+ __ LoadObjectField(closure, JSFunction::kLiteralsOffset); |
+ Node* result = __ CallRuntime(function_id, literals_array, literal_index, |
+ constant_elements, flags); |
+ __ SetAccumulator(result); |
+ __ Dispatch(); |
+} |
+ |
+ |
// CreateArrayLiteral <idx> <flags> |
// |
// Creates an array literal for literal index <idx> with flags <flags> and |