[mpas-developers] COMMIT CHECK: Updated Timers/Makefile

Doug Jacobsen jacobsen.douglas at gmail.com
Thu Oct 13 12:25:09 MDT 2011


Hi Everyone,

This email is regarding a potential commit to src/framework. I have updated
module_timer.F to have extra functionality but it *IS* backward compatible.
So, none of the existing cores that use timers will be required to change
their calls, but they can if they want to take advantage of the new
functionality.

Previously the calls to timers looked something like this:
call timer_start("total time")

where timer_start as the following interface now.
timer_start(timer_name, clear_timer, timer_ptr)

where timer_name and clear_timer are both options from the previous
interface, and timer_ptr is new.
timer_ptr essentially allows a module to keep a pointer to a timer. This
lets you have different timers with the same name. timer_stop uses this
interface as well, and timer_write's interface has not changed at all.

In addition to the interface changes, I changed the information that is
printed when timer_write it called, following this layout.

level timer_name total calls min max avg percent

Where all of these labels are self explanatory except level. Level in this
case shows the number of timers that were running when the timer was called.
total_timer should be level 0, and all timers with level 1 should be less
than or equal to the level 0 timer.

With all of these interface changes, I also added MPI timers, and PAPI
timers which are used based on compile time options. To help add in the PAPI
timers, I modified the Makefile and added three options. The three options I
added were

ifort-serial - Uses no MPI calls, and system_clock for timing
ifort-papi - Uses MPI calls with PAPI timers for timing
ifort-papi-serial - Uses no MPI calls and PAPI timers for timing

and the original

ifort - Uses MPI calls with MPI timers for timing

The modifications to the Makefile were minimal, mainly just adding an
additional variable to the LIBS variable, and building the other three
options.

I would like to commit these changes back to trunk soon, as I think they
will help everyone in profiling their cores better.

Thanks,
Doug
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/mpas-developers/attachments/20111013/1535bd4b/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Makefile
Type: application/octet-stream
Size: 5969 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/mpas-developers/attachments/20111013/1535bd4b/attachment.obj 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: module_timer.F
Type: text/x-fortran
Size: 9859 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/mpas-developers/attachments/20111013/1535bd4b/attachment.bin 


More information about the mpas-developers mailing list