OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_ARM | 7 #if V8_TARGET_ARCH_ARM |
8 | 8 |
9 #include "src/code-stubs.h" | 9 #include "src/code-stubs.h" |
10 #include "src/cpu-profiler.h" | 10 #include "src/cpu-profiler.h" |
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
89 * (in regexp-macro-assembler.cc) via the CALL_GENERATED_REGEXP_CODE macro | 89 * (in regexp-macro-assembler.cc) via the CALL_GENERATED_REGEXP_CODE macro |
90 * in arm/simulator-arm.h. | 90 * in arm/simulator-arm.h. |
91 * When calling as a non-direct call (i.e., from C++ code), the return address | 91 * When calling as a non-direct call (i.e., from C++ code), the return address |
92 * area is overwritten with the LR register by the RegExp code. When doing a | 92 * area is overwritten with the LR register by the RegExp code. When doing a |
93 * direct call from generated code, the return address is placed there by | 93 * direct call from generated code, the return address is placed there by |
94 * the calling code, as in a normal exit frame. | 94 * the calling code, as in a normal exit frame. |
95 */ | 95 */ |
96 | 96 |
97 #define __ ACCESS_MASM(masm_) | 97 #define __ ACCESS_MASM(masm_) |
98 | 98 |
99 RegExpMacroAssemblerARM::RegExpMacroAssemblerARM( | 99 RegExpMacroAssemblerARM::RegExpMacroAssemblerARM(Isolate* isolate, Zone* zone, |
100 Mode mode, | 100 Mode mode, |
101 int registers_to_save, | 101 int registers_to_save) |
102 Zone* zone) | 102 : NativeRegExpMacroAssembler(isolate, zone), |
103 : NativeRegExpMacroAssembler(zone), | 103 masm_(new MacroAssembler(isolate, NULL, kRegExpCodeSize)), |
104 masm_(new MacroAssembler(zone->isolate(), NULL, kRegExpCodeSize)), | |
105 mode_(mode), | 104 mode_(mode), |
106 num_registers_(registers_to_save), | 105 num_registers_(registers_to_save), |
107 num_saved_registers_(registers_to_save), | 106 num_saved_registers_(registers_to_save), |
108 entry_label_(), | 107 entry_label_(), |
109 start_label_(), | 108 start_label_(), |
110 success_label_(), | 109 success_label_(), |
111 backtrack_label_(), | 110 backtrack_label_(), |
112 exit_label_() { | 111 exit_label_() { |
113 DCHECK_EQ(0, registers_to_save % 2); | 112 DCHECK_EQ(0, registers_to_save % 2); |
114 __ jmp(&entry_label_); // We'll write the entry code later. | 113 __ jmp(&entry_label_); // We'll write the entry code later. |
(...skipping 1155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1270 } | 1269 } |
1271 | 1270 |
1272 | 1271 |
1273 #undef __ | 1272 #undef __ |
1274 | 1273 |
1275 #endif // V8_INTERPRETED_REGEXP | 1274 #endif // V8_INTERPRETED_REGEXP |
1276 | 1275 |
1277 }} // namespace v8::internal | 1276 }} // namespace v8::internal |
1278 | 1277 |
1279 #endif // V8_TARGET_ARCH_ARM | 1278 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |