|
Purpose
|
Sets the size of the chunk cache. |
|
Return value
|
Returns the maximum number of chunks that can be cached (the value of the parameter maxcache) if successful and FAIL (or -1) otherwise. |
|
Description
|
SDsetchunkcache sets the size of the chunk cache to the value of the parameter maxcache. |
|
|
Currently the only allowed value of the parameter flag is 0, which designates default operation. |
|
|
By default, when a generic data set is promoted to be a chunked data set, the parameter maxcache is set to the number of chunks along the fastest changing dimension and a cache for the chunks is created. |
|
|
If the chunk cache is full and the value of the parameter maxcache is greater then the current maxcache value, then the chunk cache is reset to the new value of maxcache. Otherwise the chunk cache remains at the current value of maxcache. If the chunk cache is not full, then the chunk cache is set to the new value of maxcache only if the new maxcache value is greater than the current number of chunks in the cache. |
|
|
Do not set the value of maxcache to be less than the number of chunks along the fastest-changing dimension of the biggest slab to be written or read via SDreaddata or SDwritedata. Doing this will cause internal thrashing. See the section on chunking in Chapter 13 of the HDF User's Guide, titled HDF Performance Issues, for more information on this. |