Ccm_warning is not designed to be callable by users. It is called by other routines within the module. This documentation is to show minimum information that is to be set when calling the ccm_warning routine.
Ccm_warning sets:
If the global variable ccm_auto_print is set to .true. (the default set by ccm_init) then this information is printed to standard out. If ccm_auto_print is .false. then the information is made available to the routine ccm_print_warning.
Prints error information generated by ccm_warning.
Clears error information generated by ccm_warning.
This call clears the buffers that hold error messages. It might be desirable to call this routine after calling ccm_print_warning.
|
[ccm_home:~/ccm/source] % ccm_time_x1
Warning from collective communications module
routine: scatter and data type real single precision
input array on root too small: 1
needs to be number of processors * size of input
rank of input data: 1
rank of input data: 0
calling scatter again with ccm_auto_print = T
Warning from collective communications module
routine: scatter and data type real single precision
input array on root too small: 1
needs to be number of processors * size of input
rank of input data: 2
rank of input data: 0
[ccm_home:~/ccm/source] %
The call to ccm_init initializes the communication package. We call ccm_testing with set_test=ccm_checksize so that the communications routines will check array sizes. Ccm_auto_print is set to false to suppress the automatic printings of warnings. Ccm_scatter is called with an input array of size 1. This generates a warning that is detected by checking "the_err." The program calls ccm_print_warning to pring the warning message. The message can be sent to a file by specifing a file number for ccm_print_warning. Next ccm_auto_print is set to true on task 0 to get warnings automatically printed by that task. Ccm_scatter is called again. Note for this warning message the rank of the input array is shown to be 2. The call to ccm_close closes the package. |