Lines Matching refs:bytecode

10 #include "src/interpreter/bytecode-register-allocator.h"
11 #include "src/interpreter/bytecode-register.h"
24 // Interface for bytecode pipeline stages.
29 // Write bytecode node |node| into pipeline. The node is only valid
34 // Write jump bytecode node |node| which jumps to |label| into pipeline.
40 // Binds |label| to the current bytecode location. This call implicitly
50 // Flush the pipeline and generate a bytecode array.
76 // statement position associated with 7 but no bytecode associated
133 // A container for a generated bytecode, it's operands, and source information.
137 INLINE(BytecodeNode(Bytecode bytecode,
139 : bytecode_(bytecode),
143 DCHECK_EQ(Bytecodes::NumberOfOperands(bytecode), operand_count());
146 INLINE(BytecodeNode(Bytecode bytecode, uint32_t operand0,
148 : bytecode_(bytecode),
152 DCHECK_EQ(Bytecodes::NumberOfOperands(bytecode), operand_count());
156 INLINE(BytecodeNode(Bytecode bytecode, uint32_t operand0, uint32_t operand1,
158 : bytecode_(bytecode),
162 DCHECK_EQ(Bytecodes::NumberOfOperands(bytecode), operand_count());
167 INLINE(BytecodeNode(Bytecode bytecode, uint32_t operand0, uint32_t operand1,
170 : bytecode_(bytecode),
174 DCHECK_EQ(Bytecodes::NumberOfOperands(bytecode), operand_count());
180 INLINE(BytecodeNode(Bytecode bytecode, uint32_t operand0, uint32_t operand1,
183 : bytecode_(bytecode),
187 DCHECK_EQ(Bytecodes::NumberOfOperands(bytecode), operand_count());
203 // Replace the bytecode of this node with |bytecode| and keep the operands.
204 void replace_bytecode(Bytecode bytecode) {
206 Bytecodes::NumberOfOperands(bytecode));
207 bytecode_ = bytecode;
216 // operand more than the current bytecode.
219 Bytecodes::NumberOfOperands(bytecode()) + 1);
220 DCHECK(Bytecodes::NumberOfOperands(bytecode()) < 1 ||
222 Bytecodes::GetOperandType(bytecode(), 0));
223 DCHECK(Bytecodes::NumberOfOperands(bytecode()) < 2 ||
225 Bytecodes::GetOperandType(bytecode(), 1));
226 DCHECK(Bytecodes::NumberOfOperands(bytecode()) < 3 ||
228 Bytecodes::GetOperandType(bytecode(), 2));
229 DCHECK(Bytecodes::NumberOfOperands(bytecode()) < 4);
236 Bytecode bytecode() const { return bytecode_; }
256 template <Bytecode bytecode, AccumulatorUse accumulator_use,
260 INLINE(BytecodeNode(Bytecode bytecode, int operand_count,
265 : bytecode_(bytecode),
269 DCHECK_EQ(Bytecodes::NumberOfOperands(bytecode), operand_count);
276 template <Bytecode bytecode, AccumulatorUse accum_use>
278 return BytecodeNode(bytecode, 0, OperandScale::kSingle, source_info);
281 template <Bytecode bytecode, AccumulatorUse accum_use,
285 DCHECK_EQ(Bytecodes::GetOperandType(bytecode, 0), operand0_type);
288 return BytecodeNode(bytecode, 1, scale, source_info, operand0);
291 template <Bytecode bytecode, AccumulatorUse accum_use,
295 DCHECK_EQ(Bytecodes::GetOperandType(bytecode, 0), operand0_type);
296 DCHECK_EQ(Bytecodes::GetOperandType(bytecode, 1), operand1_type);
300 return BytecodeNode(bytecode, 2, scale, source_info, operand0, operand1);
303 template <Bytecode bytecode, AccumulatorUse accum_use,
309 DCHECK_EQ(Bytecodes::GetOperandType(bytecode, 0), operand0_type);
310 DCHECK_EQ(Bytecodes::GetOperandType(bytecode, 1), operand1_type);
311 DCHECK_EQ(Bytecodes::GetOperandType(bytecode, 2), operand2_type);
316 return BytecodeNode(bytecode, 3, scale, source_info, operand0, operand1,
320 template <Bytecode bytecode, AccumulatorUse accum_use,
326 DCHECK_EQ(Bytecodes::GetOperandType(bytecode, 0), operand0_type);
327 DCHECK_EQ(Bytecodes::GetOperandType(bytecode, 1), operand1_type);
328 DCHECK_EQ(Bytecodes::GetOperandType(bytecode, 2), operand2_type);
329 DCHECK_EQ(Bytecodes::GetOperandType(bytecode, 3), operand3_type);
335 return BytecodeNode(bytecode, 4, scale, source_info, operand0, operand1,
351 if (Bytecodes::OperandIsScalableSignedByte(bytecode(), operand_index)) {
354 } else if (Bytecodes::OperandIsScalableUnsignedByte(bytecode(),