[Mono-dev] Optimized QuickSearch (System.Text.RegularExpressions)

Juraj Skripsky js at hotfeet.ch
Fri Jun 15 13:55:57 EDT 2007


Hello,

The attached patch implements an optimization for QuickSearch as
suggested by Paolo.

I've split the skip table ("Hashtable shift") into two tables:
"byte[] shift" contains skip distances for chars <= 255. "Hashtable
shiftExtended" contains skip dist. for chars > 255 (and those having
skip distances > 255). The second table is created only if necessary.

This will make the class more efficient in both time and space (for most
search strings).

Please review.

- Juraj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: quicksearch.patch
Type: text/x-patch
Size: 2412 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20070615/c4fd9c46/attachment.bin 


More information about the Mono-devel-list mailing list