LGTM

http://codereview.chromium.org/2645002/diff/2001/3001
File src/regexp.js (right):

http://codereview.chromium.org/2645002/diff/2001/3001#newcode262
src/regexp.js:262: var regexp_val;
How often do you hit this? (And how often will you hit it if you cache
negative results in the global regexp cache)?

http://codereview.chromium.org/2645002/diff/2001/3001#newcode299
src/regexp.js:299: if (%_StringCharCodeAt(this.source,0) == 46 && // '.'
You may want to try moving this.source to a local variable. It is used a
lot. Ditto for this.source.length.

http://codereview.chromium.org/2645002/diff/2001/3001#newcode313
src/regexp.js:313: if (!regexp_val.test(s)) return false;
You can cache the negative result in the regexp cache here (using the
original regexp as key). That means that next time you call test, the
global regexp cache will match and you don't even get here.

http://codereview.chromium.org/2645002/show

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to