
13 Aug
2010
13 Aug
'10
2:57 p.m.
On Friday 13 August 2010 19:53:37 you wrote:
On Fri, Aug 13, 2010 at 9:55 AM, Daniel Fischer
wrote: That's an unfortunate example. Using the stringsearch package, substring searching in ByteStrings was considerably faster than in Data.Text in my tests.
Interesting. Got a test case so I can repro and fix? :-)
Just occurred to me, a lot of the difference is due to the fact that text has to convert a ByteString to Text on reading the file, so I timed that by reading the file and counting the chunks, that took text 0.21s for big.txt vs. Data.ByteString.Lazy's 0.01s. So for searching in-memory strings, subtract about 0.032s/MB from the difference - it's still large.