Ignore:
Timestamp:
Sep 23, 2010, 3:23:19 PM (15 years ago)
Author:
[email protected]
Message:

2010-09-23 Michael Saboff <[email protected]>

Reviewed by Geoffrey Garen.

Removed extraneous truncation of ovector on entry and error exit.
Changed the initialization to -1 of vector to only initialize
the start indecies, which is sufficient for the pattern/subpatterns.
Changed the JIT code to not clear the end index for subpatterns
as it isn't needed. These changes are worth ~2.7% on v8-regexp.
https://bugs.webkit.org/show_bug.cgi?id=46404

  • runtime/RegExp.cpp: (JSC::RegExp::match):
  • yarr/RegexJIT.cpp: (JSC::Yarr::RegexGenerator::generateParenthesesSingle):
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/yarr/RegexJIT.cpp

    r68100 r68207  
    987987            // A failure WITHIN the parens jumps here
    988988            parenthesesState.linkAlternativeBacktracks(this);
    989             if (term.invertOrCapture) {
     989            if (term.invertOrCapture)
    990990                store32(Imm32(-1), Address(output, (term.parentheses.subpatternId << 1) * sizeof(int)));
    991                 store32(Imm32(-1), Address(output, ((term.parentheses.subpatternId << 1) + 1) * sizeof(int)));
    992             }
    993991
    994992            if (term.quantityType == QuantifierGreedy)
Note: See TracChangeset for help on using the changeset viewer.