/[MITgcm]/MITgcm/pkg/showflops/showflops_insolve.F
ViewVC logotype

Contents of /MITgcm/pkg/showflops/showflops_insolve.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.4 - (show annotations) (download)
Sat Jul 7 00:08:09 2012 UTC (12 years ago) by jmc
Branch: MAIN
CVS Tags: checkpoint64y, checkpoint64x, checkpoint64z, checkpoint64q, checkpoint64p, checkpoint64s, checkpoint64r, checkpoint64u, checkpoint64t, checkpoint64w, checkpoint64v, checkpoint64i, checkpoint64h, checkpoint64k, checkpoint64j, checkpoint64m, checkpoint64l, checkpoint64o, checkpoint64n, checkpoint64a, checkpoint64c, checkpoint64b, checkpoint64e, checkpoint64d, checkpoint64g, checkpoint64f, checkpoint63q, checkpoint63r, checkpoint63s, checkpoint64, checkpoint65, checkpoint66g, checkpoint66f, checkpoint66e, checkpoint66d, checkpoint66c, checkpoint66b, checkpoint66a, checkpoint66o, checkpoint66n, checkpoint66m, checkpoint66l, checkpoint66k, checkpoint66j, checkpoint66i, checkpoint66h, checkpoint65z, checkpoint65x, checkpoint65y, checkpoint65r, checkpoint65s, checkpoint65p, checkpoint65q, checkpoint65v, checkpoint65w, checkpoint65t, checkpoint65u, checkpoint65j, checkpoint65k, checkpoint65h, checkpoint65i, checkpoint65n, checkpoint65o, checkpoint65l, checkpoint65m, checkpoint65b, checkpoint65c, checkpoint65a, checkpoint65f, checkpoint65g, checkpoint65d, checkpoint65e, HEAD
Changes since 1.3: +7 -8 lines
uses standard #indude ${PKG}_OPTIONS.h

1 C $Header: /u/gcmpack/MITgcm/pkg/showflops/showflops_insolve.F,v 1.3 2007/09/20 20:58:37 ce107 Exp $
2 C $Name: $
3
4 #include "SHOWFLOPS_OPTIONS.h"
5
6 CBOP
7 C !ROUTINE: SHOWFLOPS_INSOLVE
8 C !INTERFACE:
9 SUBROUTINE SHOWFLOPS_INSOLVE( myThid )
10
11 C !DESCRIPTION: \bv
12 C *================================================================*
13 C | SUBROUTINE showflops_insolve
14 C | o Do runtime timing
15 C *================================================================*
16 C \ev
17
18 C !USES:
19 IMPLICIT NONE
20 C == Global variables ==
21 #include "SIZE.h"
22 #include "EEPARAMS.h"
23 #include "PARAMS.h"
24 #include "SHOWFLOPS.h"
25
26 C !INPUT/OUTPUT PARAMETERS:
27 C == Routine arguments ==
28 C note: under the multi-threaded model myiter and
29 C mytime are local variables passed around as routine
30 C arguments. Although this is fiddly it saves the need to
31 C impose additional synchronisation points when they are
32 C updated.
33 C myThid - thread number for this instance of the routine.
34 integer iloop
35 INTEGER myThid
36
37 C !FUNCTIONS:
38 C == Functions ==
39 #ifdef ALLOW_RUNCLOCK
40 LOGICAL RUNCLOCK_CONTINUE
41 LOGICAL RC_CONT
42 #endif
43
44 C !LOCAL VARIABLES:
45 C == Local variables ==
46
47 CEOP
48
49 #ifdef ALLOW_DEBUG
50 IF (debugMode) CALL DEBUG_ENTER('SHOWFLOPS_INSOLVE',myThid)
51 #endif
52
53 #ifdef TIME_PER_TIMESTEP_SFP
54 CCE107 Time per timestep information
55 _BEGIN_MASTER( myThid )
56 CALL TIMER_GET_TIME( utnew, stnew, wtnew )
57 C Only output timing information after the 1st timestep
58 IF ( wtold .NE. 0.0D0 ) THEN
59 WRITE(msgBuf,'(A34,3F10.6)')
60 $ 'User, system and wallclock time:', utnew - utold,
61 $ stnew - stold, wtnew - wtold
62 CALL PRINT_MESSAGE(msgBuf,standardMessageUnit,SQUEEZE_RIGHT,1)
63 ENDIF
64 utold = utnew
65 stold = stnew
66 wtold = wtnew
67 _END_MASTER( myThid )
68 #endif
69 #ifdef USE_PAPI_FLOPS_SFP
70 CCE107 PAPI summary performance
71 _BEGIN_MASTER( myThid )
72 #ifdef USE_FLIPS
73 call PAPIF_flips(real_time, proc_time, flpops, mflops, check)
74 #else
75 call PAPIF_flops(real_time, proc_time, flpops, mflops, check)
76 #endif
77 WRITE(msgBuf,'(A34,F12.6,A,F12.6)')
78 $ 'Mflop/s during this timestep:', mflops, ' ', mflops
79 $ *proc_time/(real_time + 1E-36)
80 CALL PRINT_MESSAGE(msgBuf,standardMessageUnit,SQUEEZE_RIGHT,1)
81 #ifdef PAPI_VERSION
82 call PAPIF_ipc(real_time, proc_time, instr, ipc, check)
83 WRITE(msgBuf,'(A34,F12.6,A,F12.6)')
84 $ 'IPC during this timestep:', ipc, ' ', ipc*proc_time
85 $ /(real_time + 1E-36)
86 CALL PRINT_MESSAGE(msgBuf,standardMessageUnit,SQUEEZE_RIGHT,1)
87 #endif
88 _END_MASTER( myThid )
89 #else
90 #ifdef USE_PCL_FLOPS_SFP
91 CCE107 PCL summary performance
92 _BEGIN_MASTER( myThid )
93 PCLstop(descr, i_result, fp_result, nevents)
94 do ipcl = 1, nevents
95 WRITE(msgBuf,'(A22,A26,F12.6)'),
96 $ pcl_counter_name(pcl_counter_list(ipcl)),
97 $ 'during this timestep:', fp_results(ipcl)
98 CALL PRINT_MESSAGE(msgBuf,standardMessageUnit,SQUEEZE_RIGHT,1)
99 enddo
100 PCLstart(descr, pcl_counter_list, nevents, flags)
101 _END_MASTER( myThid )
102 #endif
103 #endif
104
105 #ifdef ALLOW_DEBUG
106 IF (debugMode) CALL DEBUG_LEAVE('SHOWFLOPS_INSOLVE',myThid)
107 #endif
108
109 END
110

  ViewVC Help
Powered by ViewVC 1.1.22