performance problem in regex
Michel Talon
talon at lpthe.jussieu.fr
Thu Oct 9 14:31:37 UTC 2008
fulvio_esposito wrote:
> I've got some performance hit using regex in libc on freebsd 6.3
Knowing that this regex implementation uses an NFA algorithm, while
a DFA algorithm should be preferred, this is no big surprise. You can
read the following references on the subject:
http://swtch.com/~rsc/regexp/regexp1.html
http://www.dmst.aueb.gr/dds/pubs/jrnl/2007-SPANDE-FIRE/html/KS07.html
In particular the second is written by a FreeBSD developer and states:
"The Spencer engine proved to have poor performance and was excluded
from the graphs.", where the Spencer engine is precisely the one in
FreeBSD.
--
Michel TALON
More information about the freebsd-questions
mailing list