Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(218)

Side by Side Diff: src/regexp/arm/regexp-macro-assembler-arm.h

Issue 1418963009: Experimental support for RegExp lookbehind. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix arm64 debug code assertion Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/parser.cc ('k') | src/regexp/arm/regexp-macro-assembler-arm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef V8_REGEXP_ARM_REGEXP_MACRO_ASSEMBLER_ARM_H_ 5 #ifndef V8_REGEXP_ARM_REGEXP_MACRO_ASSEMBLER_ARM_H_
6 #define V8_REGEXP_ARM_REGEXP_MACRO_ASSEMBLER_ARM_H_ 6 #define V8_REGEXP_ARM_REGEXP_MACRO_ASSEMBLER_ARM_H_
7 7
8 #include "src/arm/assembler-arm.h" 8 #include "src/arm/assembler-arm.h"
9 #include "src/macro-assembler.h" 9 #include "src/macro-assembler.h"
10 #include "src/regexp/regexp-macro-assembler.h" 10 #include "src/regexp/regexp-macro-assembler.h"
(...skipping 16 matching lines...) Expand all
27 virtual void CheckAtStart(Label* on_at_start); 27 virtual void CheckAtStart(Label* on_at_start);
28 virtual void CheckCharacter(unsigned c, Label* on_equal); 28 virtual void CheckCharacter(unsigned c, Label* on_equal);
29 virtual void CheckCharacterAfterAnd(unsigned c, 29 virtual void CheckCharacterAfterAnd(unsigned c,
30 unsigned mask, 30 unsigned mask,
31 Label* on_equal); 31 Label* on_equal);
32 virtual void CheckCharacterGT(uc16 limit, Label* on_greater); 32 virtual void CheckCharacterGT(uc16 limit, Label* on_greater);
33 virtual void CheckCharacterLT(uc16 limit, Label* on_less); 33 virtual void CheckCharacterLT(uc16 limit, Label* on_less);
34 // A "greedy loop" is a loop that is both greedy and with a simple 34 // A "greedy loop" is a loop that is both greedy and with a simple
35 // body. It has a particularly simple implementation. 35 // body. It has a particularly simple implementation.
36 virtual void CheckGreedyLoop(Label* on_tos_equals_current_position); 36 virtual void CheckGreedyLoop(Label* on_tos_equals_current_position);
37 virtual void CheckNotAtStart(Label* on_not_at_start); 37 virtual void CheckNotAtStart(int cp_offset, Label* on_not_at_start);
38 virtual void CheckNotBackReference(int start_reg, Label* on_no_match); 38 virtual void CheckNotBackReference(int start_reg, bool read_backward,
39 Label* on_no_match);
39 virtual void CheckNotBackReferenceIgnoreCase(int start_reg, 40 virtual void CheckNotBackReferenceIgnoreCase(int start_reg,
41 bool read_backward,
40 Label* on_no_match); 42 Label* on_no_match);
41 virtual void CheckNotCharacter(unsigned c, Label* on_not_equal); 43 virtual void CheckNotCharacter(unsigned c, Label* on_not_equal);
42 virtual void CheckNotCharacterAfterAnd(unsigned c, 44 virtual void CheckNotCharacterAfterAnd(unsigned c,
43 unsigned mask, 45 unsigned mask,
44 Label* on_not_equal); 46 Label* on_not_equal);
45 virtual void CheckNotCharacterAfterMinusAnd(uc16 c, 47 virtual void CheckNotCharacterAfterMinusAnd(uc16 c,
46 uc16 minus, 48 uc16 minus,
47 uc16 mask, 49 uc16 mask,
48 Label* on_not_equal); 50 Label* on_not_equal);
49 virtual void CheckCharacterInRange(uc16 from, 51 virtual void CheckCharacterInRange(uc16 from,
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 114
113 // Below the frame pointer. 115 // Below the frame pointer.
114 // Register parameters stored by setup code. 116 // Register parameters stored by setup code.
115 static const int kInputEnd = kFramePointer - kPointerSize; 117 static const int kInputEnd = kFramePointer - kPointerSize;
116 static const int kInputStart = kInputEnd - kPointerSize; 118 static const int kInputStart = kInputEnd - kPointerSize;
117 static const int kStartIndex = kInputStart - kPointerSize; 119 static const int kStartIndex = kInputStart - kPointerSize;
118 static const int kInputString = kStartIndex - kPointerSize; 120 static const int kInputString = kStartIndex - kPointerSize;
119 // When adding local variables remember to push space for them in 121 // When adding local variables remember to push space for them in
120 // the frame in GetCode. 122 // the frame in GetCode.
121 static const int kSuccessfulCaptures = kInputString - kPointerSize; 123 static const int kSuccessfulCaptures = kInputString - kPointerSize;
122 static const int kInputStartMinusOne = kSuccessfulCaptures - kPointerSize; 124 static const int kStringStartMinusOne = kSuccessfulCaptures - kPointerSize;
123 // First register address. Following registers are below it on the stack. 125 // First register address. Following registers are below it on the stack.
124 static const int kRegisterZero = kInputStartMinusOne - kPointerSize; 126 static const int kRegisterZero = kStringStartMinusOne - kPointerSize;
125 127
126 // Initial size of code buffer. 128 // Initial size of code buffer.
127 static const size_t kRegExpCodeSize = 1024; 129 static const size_t kRegExpCodeSize = 1024;
128 130
129 static const int kBacktrackConstantPoolSize = 4; 131 static const int kBacktrackConstantPoolSize = 4;
130 132
131 // Load a number of characters at the given offset from the 133 // Load a number of characters at the given offset from the
132 // current position, into the current-character register. 134 // current position, into the current-character register.
133 void LoadCurrentCharacterUnchecked(int cp_offset, int character_count); 135 void LoadCurrentCharacterUnchecked(int cp_offset, int character_count);
134 136
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 Label stack_overflow_label_; 213 Label stack_overflow_label_;
212 }; 214 };
213 215
214 #endif // V8_INTERPRETED_REGEXP 216 #endif // V8_INTERPRETED_REGEXP
215 217
216 218
217 } // namespace internal 219 } // namespace internal
218 } // namespace v8 220 } // namespace v8
219 221
220 #endif // V8_REGEXP_ARM_REGEXP_MACRO_ASSEMBLER_ARM_H_ 222 #endif // V8_REGEXP_ARM_REGEXP_MACRO_ASSEMBLER_ARM_H_
OLDNEW
« no previous file with comments | « src/parser.cc ('k') | src/regexp/arm/regexp-macro-assembler-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698