Bug 15998

Summary: Abstract much of RMATCH into MatchStack functions
Product: WebKit Reporter: Eric Seidel (no email) <eric>
Component: JavaScriptCoreAssignee: Eric Seidel (no email) <eric>
Status: RESOLVED FIXED    
Severity: Normal    
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.4   
Bug Depends on: 15996    
Bug Blocks:    
Attachments:
Description Flags
abstract RMATCH into MatchStack functions
none
abstract RMATCH into MatchStack functions sam: review+

Description Eric Seidel (no email) 2007-11-15 03:25:03 PST
Abstract much of RMATCH into MatchStack functions

I'm preparing to further cleanup "recursion" in match(), starting by making RMATCH() much much smaller.  Currently I'm inlining the frame management (since that's how it was before).  I'm not sure that will be a win in the end.

This patch actually caused my SunSpider results to stabilize, showing no slowdowns, a 9.3% improvement in regex-dna, and a 1.0% win over all (combined improvements from this and bug 15996)
Comment 1 Eric Seidel (no email) 2007-11-15 03:25:58 PST
Created attachment 17290 [details]
abstract RMATCH into MatchStack functions
Comment 2 Eric Seidel (no email) 2007-11-15 03:26:33 PST
Created attachment 17291 [details]
abstract RMATCH into MatchStack functions
Comment 3 Sam Weinig 2007-11-15 10:51:36 PST
Comment on attachment 17291 [details]
abstract RMATCH into MatchStack functions

The typedef should not be necessary in c++.
+typedef struct matchframe {

nor should this explicit struct
+  struct matchframe* prevframe;

r=me.
Comment 4 Eric Seidel (no email) 2007-11-15 16:15:02 PST
Landed.