5 #ifndef V8_REGEXP_REGEXP_MACRO_ASSEMBLER_IRREGEXP_INL_H_ 6 #define V8_REGEXP_REGEXP_MACRO_ASSEMBLER_IRREGEXP_INL_H_ 8 #ifdef V8_INTERPRETED_REGEXP 10 #include "src/regexp/regexp-macro-assembler-irregexp.h" 12 #include "src/ast/ast.h" 13 #include "src/regexp/bytecodes-irregexp.h" 18 void RegExpMacroAssemblerIrregexp::Emit(
uint32_t byte,
20 uint32_t word = ((twenty_four_bits << BYTECODE_SHIFT) | byte);
21 DCHECK(pc_ <= buffer_.length());
22 if (pc_ + 3 >= buffer_.length()) {
25 *
reinterpret_cast<uint32_t*
>(buffer_.start() + pc_) = word;
30 void RegExpMacroAssemblerIrregexp::Emit16(
uint32_t word) {
31 DCHECK(pc_ <= buffer_.length());
32 if (pc_ + 1 >= buffer_.length()) {
35 *
reinterpret_cast<uint16_t*
>(buffer_.start() + pc_) = word;
40 void RegExpMacroAssemblerIrregexp::Emit8(
uint32_t word) {
41 DCHECK(pc_ <= buffer_.length());
42 if (pc_ == buffer_.length()) {
45 *
reinterpret_cast<unsigned char*
>(buffer_.start() + pc_) = word;
50 void RegExpMacroAssemblerIrregexp::Emit32(
uint32_t word) {
51 DCHECK(pc_ <= buffer_.length());
52 if (pc_ + 3 >= buffer_.length()) {
55 *
reinterpret_cast<uint32_t*
>(buffer_.start() + pc_) = word;
62 #endif // V8_INTERPRETED_REGEXP 64 #endif // V8_REGEXP_REGEXP_MACRO_ASSEMBLER_IRREGEXP_INL_H_