On 2007-12-11 02:44 +0900 (Tue), Robert Klemme wrote:

> This is what I'd do: create a single string per line and use substring
> (aka #[]) to create strings that represent the portion needed; byte
> buffer will be shared then. You don't even need to freeze them because
> of copy on write.

This was attractive for a couple of seconds, until I realized that not
only does it still add a copy of the entire row of data (albeit as one
large allocation rather than many small ones), but it also doesn't
reduce my object creation load at all. I seem to recall last time I was
playing around with this sort of thing and using a profiler, GC was an
enormous cost for me. This probably isn't surprising given the nature of
the problem; a typical file might be ten million rows of fifty elements
each, which would be 500 million object creations and collections.

cjs
-- 
Curt Sampson       <cjs / starling-software.com>        +81 90 7737 2974   
Mobile sites and software consulting: http://www.starling-software.com