
Sorry for jumping in. IIUC the largest speedup was delivered by moving a
reger compilation expression out of a loop. If the regex compilation is a
pure function, being passed the exact same arguments during every
invocation of the loop, shouldn't the compiler be smart enough to optimise
it? Isnt this the basic premise of pure FP?
On 30-May-2017 2:20 AM, "Brandon Allbery"
* I switched from Text.Regex.TDFA to Text.Regex.PCRE (as I think you observed, judging by your commit messages), it seems to be somewhat faster, at lease for these relatively small data sets;
TDFA is pure Haskell and mostly exists for when you can't be certain that a faster C binding will support UTF8 (most POSIX regex implementations do not, and PCRE only does so if someone built it with UTF8 support). When it's usable, the C bindings will almost always be faster. -- brandon s allbery kf8nh sine nomine associates allbery.b@gmail.com ballbery@sinenomine.net unix, openafs, kerberos, infrastructure, xmonad http://sinenomine.net _______________________________________________ Haskell-Cafe mailing list To (un)subscribe, modify options or view archives go to: http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe Only members subscribed via the mailman list are allowed to post.