[FWTools] MrSID Reader performance?

Frank Warmerdam warmerdam at pobox.com
Wed Feb 7 20:18:28 EST 2007


Jason Birch wrote:
> FrankW wrote:
> 
>> I suspect you are seeing cache thrashing in which case
>> you will want to set the GDAL_CACHEMAX environment 
>> variable to a fair sized number (eg. 200).
> 
> Thanks Frank, that has helped immensely.
> 
> Is there a downside to setting that value really high, other than taking
> the memory away from other system processes?  
> 
> I don't see any real performance difference between 200MB and 500MB
> (about 100KB/s output), so this seems like it's one of those things that
> doesn't matter unless you hit a certain threshold, but hitting that
> threshold is something I'd like to avoid in the future :)

Jason,

The threshold is the point at which the cache is no longer big enough
to hold a complete row of tiles.  Once you exceed that each output scanline
results in all the tiles for that scanline being reread.

> I think when I set it to 1000 it behaved as if it was not set at all.

I see the logic in the code assumes that a value of less than 1000 must be
in megabytes while otherwise it is interpreted as being in bytes.  That's
pretty perverse in this day and age.

I've change this to 10000 so any value less than 10000 is assumed to be
in megabytes instead of bytes.  I'm also changing the default from 10MB
to 40MB and I'll retrofit this back into 1.4.x branch.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | President OSGeo, http://osgeo.org



More information about the FWTools mailing list