15% of string-validate-input.js is spent compiling the same regular expression
I thought that ggaren fixed this with 15861, but it seems not. Unless I'm somehow missing his change in my git-repo.
I tried moving "pattern" outside of the loop in string-validate-input.js and saw a 15% speed increase. Looking at the shark sample, we're still spending all our time compiling the regexp. Maybe the patch he landed as part of the old bug was just the "first step in the right direction". Well, here is a bug to cover the other steps. :)
Of course, even moving pattern outside of the loop for our test run, we're still 38% slower:
validate-input: 31.8% *slower* 106.4ms +/- 0.6% 140.2ms +/- 1.7% significant
than spidermonkey is for this test. :(
*** This bug has been marked as a duplicate of 15902 ***