Unidata - To provide the data services, tools, and cyberinfrastructure leadership that advance Earth system science, enhance educational opportunities, and broaden participation. Unidata
         
  advanced  
 

netcdf on the Cray, once more..

I would assume that the cost of writing large float arrays on the cray
comes from:
        1) converting the floats to ieee format
        2) the xdr overhead, especially array loops.

On point one, there might be a system library to do this fast. I also
heard a rumor that Cray is going to change to ieee format (???)

On point two, it would be a worthwhile optimization to replace the
xdr_array() routine with something that is optimized for floats. I
belive that the standard routine will make (at least) one function call
for every array element.  

Combining these two ideas would mean that you would add some specialized
code to xdr_array(), eg in psuedo-code:

        if (type == float)
           {
           system_convert_to_ieee( my_array, out_array, n_elems);
           place_in_xdr_buffer( out_array, length);
           }


> (My conversion program takes about twice the time on the C90 compared
> to a HP workstation.)

I assume this is the ieee conversion, unless HP optimized xdr_array().
What is time difference of netcdf write and binary write for typical
large scientific datasets? Is it dominated by xdr_array() ?

It might be generally useful to avoid the function call / element overhead
on all machines. Does Unidata want to investigate / support such a mod?


 
 
  Contact Us     Site Map     Search     Terms and Conditions     Privacy Policy     Participation Policy
 
National Science Foundation (NSF) UCAR Community Programs   Unidata is a member of the UCAR Community Programs, is managed by the University Corporation for Atmospheric Research, and is sponsored by the National Science Foundation.
P.O. Box 3000     Boulder, CO 80307-3000 USA     Tel: 303-497-8643     Fax: 303-497-8690