| Index: src/regexp-macro-assembler-ia32.h
|
| diff --git a/src/regexp-macro-assembler-ia32.h b/src/regexp-macro-assembler-ia32.h
|
| index de653d57044ef83441fa48f7943ca2733d5d2015..44dd941f955486d36c93bb1cd4e8a1cde0689fd5 100644
|
| --- a/src/regexp-macro-assembler-ia32.h
|
| +++ b/src/regexp-macro-assembler-ia32.h
|
| @@ -88,6 +88,19 @@ class RegExpMacroAssemblerIA32: public RegExpMacroAssembler {
|
| virtual void WriteCurrentPositionToRegister(int reg);
|
| virtual void WriteStackPointerToRegister(int reg);
|
|
|
| + template <typename T>
|
| + static inline bool Execute(Code* code,
|
| + T** input,
|
| + int start_offset,
|
| + int end_offset,
|
| + int* output,
|
| + bool at_start) {
|
| + typedef bool (*matcher)(T**, int, int, int*, int);
|
| + matcher matcher_func = FUNCTION_CAST<matcher>(code->entry());
|
| + int at_start_val = at_start ? 1 : 0;
|
| + return matcher_func(input, start_offset, end_offset, output, at_start_val);
|
| + }
|
| +
|
| private:
|
| // Offsets from ebp of arguments to function.
|
| static const int kBackup_ebx = sizeof(uint32_t);
|
| @@ -98,6 +111,7 @@ class RegExpMacroAssemblerIA32: public RegExpMacroAssembler {
|
| static const int kInputStartOffset = kInputBuffer + sizeof(uint32_t);
|
| static const int kInputEndOffset = kInputStartOffset + sizeof(uint32_t);
|
| static const int kRegisterOutput = kInputEndOffset + sizeof(uint32_t);
|
| + static const int kAtStart = kRegisterOutput + sizeof(uint32_t);
|
|
|
| // Initial size of code buffer.
|
| static const size_t kRegExpCodeSize = 1024;
|
| @@ -114,10 +128,6 @@ class RegExpMacroAssemblerIA32: public RegExpMacroAssembler {
|
| // Byte size of chars in the string to match (decided by the Mode argument)
|
| size_t char_size();
|
|
|
| - // Records that a register is used. At the end, we need the number of
|
| - // registers used.
|
| - void RecordRegister(int register_index);
|
| -
|
| // Equivalent to a conditional branch to the label, unless the label
|
| // is NULL, in which case it is a conditional Backtrack.
|
| void BranchOrBacktrack(Condition condition, Label* to);
|
|
|