PROFILE report

Bug reports, work arounds and fixes

Moderators: arango, robertson

Post Reply
Message
Author
User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

PROFILE report

#1 Unread post by kate »

I used to get profile reports, but haven't in quite some time now. I went into the debugger to find out why it's not printing. There's this test:

Code: Select all

IF (thread_count.eq.numthreads) THEN
thread_count is 2 at this point, being initialized to 0, then incremented both during initialization and in the wrap-up. numthreads is the number of processes, here 4. Therefore the if condition fails and nothing gets printed beyond this:

Code: Select all

 Elapsed CPU time (seconds):

 Node   #  3 CPU:      83.468
 Node   #  1 CPU:      83.468
 Node   #  2 CPU:      83.468
 Node   #  0 CPU:      83.468
What's the best way to fix this?
Last edited by kate on Wed Jul 16, 2014 4:06 pm, edited 1 time in total.

hugobastos
Posts: 15
Joined: Tue May 06, 2008 8:46 pm
Location: FURG

Re: PROFILE report

#2 Unread post by hugobastos »

Hi Kate, did you find a correction for this? I'm missing the profile reports too...

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: PROFILE report

#3 Unread post by kate »

No, I got no reply. I'm guessing one possible fix for those of us who only use MPI would be to comment out the IF test.

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: PROFILE report

#4 Unread post by kate »

Not safe for OpenMP, but I got desperate for a profile report and made this change:

Code: Select all

diff --git a/ROMS/Utility/timers.F b/ROMS/Utility/timers.F
index a943335..548e09e 100644
--- a/ROMS/Utility/timers.F
+++ b/ROMS/Utility/timers.F
@@ -176,7 +176,7 @@
             END DO
           END IF
         END DO
-        IF (thread_count.eq.numthreads) THEN
+!        IF (thread_count.eq.numthreads) THEN
           thread_count=0
 #ifdef DISTRIBUTE
           op_handle(0:Nregion)='SUM'
@@ -269,7 +269,7 @@
   60      FORMAT (/,' All percentages are with respect to total time =',&
      &            5x,f12.3)
 #endif-
-        END IF
+!        END IF
 !$OMP END CRITICAL (FINALIZE_WCLOCK)
       END IF
       RETURN
Sure enough, the report came back.

User avatar
arango
Site Admin
Posts: 1367
Joined: Wed Feb 26, 2003 4:41 pm
Location: DMCS, Rutgers University
Contact:

Re: PROFILE report

#5 Unread post by arango »

This is in my to do list. I had noticed it too. The logic is delicate because of shared-memory. I am busy with other codes now.

Post Reply