[Wrf-users] Bug in WRF 3.2.1 RSL_LITE library
Kemp, Eric M. (GSFC-610.0)[NORTHROP GRUMMAN INFORMATION TECH]
eric.kemp at nasa.gov
Mon Feb 28 11:08:51 MST 2011
Dear wrfhelp:
I continue to investigate a problem I reported several months ago: occasional CFL errors and/or crashes with identical initial conditions when running a particular domain. While I have not found a solution to this problem, I have found a bug in the RSL_LITE library.
In WRFV3/external/RSL_LITE/c_code.c, function RSL_LITE_INIT_EXCH contains two local variables (nbytes_x_recv and nbytes_y_recv). These variables are declared without initial values. If the code is compiled with MPI support, these variables are assigned values within if blocks (i.e., under special conditions; in some cases the statements in the if blocks are not executed). If RSL_LITE is compiled serially, then the if statements are removed by the preprocessor. At the end of the function (near line 300), these variables are used to calculate xp_curs_recv and yp_curs_recv.
My bug patch:
Near line 229:
#ifndef STUBMPI
MPI_Comm comm, *comm0, dummy_comm ;
nbytes_x_recv = 0; /* Bug fix */
nbytes_y_recv = 0; /* Bug fix */
comm0 = &dummy_comm ;
Near line 295:
buffer_for_proc ( xm , nbytes, RSL_SENDBUF ) ;
}
}
#else /* Bug fix */
nbytes_x_recv = 0; /* Bug fix */
nbytes_y_recv = 0; /* Bug fix */
#endif
yp_curs = 0 ; ym_curs = 0 ; xp_curs = 0 ; xm_curs = 0 ;
I found this bug using ifort 11.1.038 and the “-check” compiler flag.
Cheers,
-Eric
--------------------------------------------------------------------
Eric M. Kemp Northrop Grumman Corporation
Meteorologist Information Systems
Civil Enterprise Solutions Civil Systems Division
Goddard Space Flight Center
Mailstop 610.3
Greenbelt, MD 20771
Telephone 301-286-9768
Fax 301-286-1775
E-mail: eric.kemp at nasa.gov
E-mail: eric.kemp at ngc.com
--------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/wrf-users/attachments/20110228/be7b01df/attachment.html
More information about the Wrf-users
mailing list