?? readme
字號:
Code in this directory implements a set of general-purpose thread-safe timingroutines, callable from Fortran or C. Only the Fortran interface will bediscussed here. Normal usage is as follows:#include "gpt.inc"...t_setoptionf (timing_option, 0 or 1)...t_initializef ()...t_startf ('arbitrary_timer_name')...t_stopf ('arbitrary_timer_name')...t_prf (mpi_task_id)alsot_stampf (wall, usr, sys)An arbitrary number of calls to t_setoptionf() preceeds a single call tot_initializef(), and all should be within a non-threaded code region.Default behavior with zero calls to t_setoptionf() is to output statisticsfor user time, system time, and wallclock time. The function's purpose is tomodify this default behavior. For example, t_setoptionf (usrsys, 0) turnsoff user and system timings. t_setoptionf (wall, 1) turns on wallclocktimings. Other options (e.g. pcl_l1dcache_miss) are not available in thecommitted code. Include file gpt.inc need only be included wheret_setoptionf() is called.An arbitrary sequence of (potentially nested) paired calls to t_startf() andt_stopf() with unique timer names of up to 15 characters each can then occur.The call to t_prf() will produce a summary of all timer values. The argumentto t_prf() is normally the MPI task id, but can be any integer. The outputfile with the timing information will be named timing.<num>. If threadingwas enabled and timing calls were made from within threaded regions of thecode, a per-thread summary will be included in this output file.Stand-alone routine t_stampf(wall, usr, sys) can be called to returnvalues for use in the application code. The wallclock user, and systemtimestamps returned are real*8 numbers in units of seconds.The underlying library routine used to gather user and system times istimes(). Unfortunately, the behavior of this routine is not consistentacross platforms. On IBM and Compaq, it is cumulative across threads. OnSGI and PC machines it is thread-specific. This behavior will be reflectedin the printed timings. For example, on a 4-PE dedicated node the user timefor a given routine called from within a threaded region may exceed thewallclock number by as much as a factor of 4 on IBM and Compaq machines.
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -