[MITgcm-devel] compiler optimization on SunOS

Martin Losch Martin.Losch at awi.de
Sun Feb 18 07:56:18 EST 2007


Hi there,
I have traced down the optimization problem to this section:
>         DO K=Nr,1,-1
>          DO j=1,sNy+1
>           DO i=1,sNx+1
>            uf(i,j) = _dyG(i,j,bi,bj)*deepFacC(k)
>      &               *drF(k)*_hFacW(i,j,k,bi,bj)*rhoFacC(k)
>            vf(i,j) = _dxG(i,j,bi,bj)*deepFacC(k)
>      &               *drF(k)*_hFacS(i,j,k,bi,bj)*rhoFacC(k)
>           ENDDO
>          ENDDO
>          CALL CALC_DIV_GHAT(
>      I       bi,bj,1,sNx,1,sNy,K,
>      I       uf,vf,
>      U       cg2d_b,
>      I       myThid)
>         ENDDO
When I increase the loop ranges to 1-Oly,sNy+Oly and 1-Olx,sNx+Olx,  
everything is fine even with the high optimization level. What do you  
think about increasing these loop ranges, or at least initializtion  
vf and uf properly (I didn't try yet, if that would work, too).

Martin



More information about the MITgcm-devel mailing list