Ignore:
Timestamp:
Jun 11, 2020, 11:09:38 AM (4 years ago)
Author:
adurocher
Message:

Added timers for physiq and display physic profiling

Location:
LMDZ6/branches/Optimisation_LMDZ/libf/phy_common
Files:
1 added
1 edited

Legend:

Unmodified
Added
Removed
  • LMDZ6/branches/Optimisation_LMDZ/libf/phy_common/mod_phys_lmdz_mpi_transfert.F90

    r3465 r3706  
    4646                     reduce_min_mpi_r,reduce_min_mpi_r1,reduce_min_mpi_r2,reduce_min_mpi_r3,reduce_min_mpi_r4
    4747  END INTERFACE
     48 
     49  INTERFACE reduce_max_mpi
     50    MODULE PROCEDURE reduce_max_mpi_r
     51  END INTERFACE
    4852
    4953 INTERFACE grid1dTo2d_mpi
     
    11151119  END SUBROUTINE reduce_min_mpi_r4
    11161120
    1117 
     1121  SUBROUTINE reduce_max_mpi_r(VarIn, VarOut)
     1122    USE mod_phys_lmdz_mpi_data, ONLY :  is_mpi_root
     1123    IMPLICIT NONE
     1124 
     1125    REAL,INTENT(IN)  :: VarIn
     1126    REAL,INTENT(OUT) :: VarOut
     1127    REAL             :: VarIn_tmp(1)
     1128    REAL             :: VarOut_tmp(1)
     1129   
     1130    VarIn_tmp(1)=VarIn   
     1131    CALL reduce_max_mpi_rgen(VarIn_tmp,Varout_tmp,1)
     1132    VarOut=VarOut_tmp(1)
     1133 
     1134  END SUBROUTINE reduce_max_mpi_r
    11181135
    11191136
     
    18051822       
    18061823  END SUBROUTINE reduce_sum_mpi_rgen
     1824 
     1825  SUBROUTINE reduce_max_mpi_rgen(VarIn,VarOut,nb)
     1826    USE mod_phys_lmdz_mpi_data
     1827    USE mod_grid_phy_lmdz
     1828
     1829    IMPLICIT NONE
     1830
     1831#ifdef CPP_MPI
     1832    INCLUDE 'mpif.h'
     1833#endif
     1834   
     1835    INTEGER,INTENT(IN) :: nb
     1836    REAL,DIMENSION(nb),INTENT(IN) :: VarIn
     1837    REAL,DIMENSION(nb),INTENT(OUT) :: VarOut   
     1838    INTEGER :: ierr
     1839 
     1840    IF (.not.is_using_mpi) THEN
     1841      VarOut(:)=VarIn(:)
     1842      RETURN
     1843    ENDIF
     1844   
     1845#ifdef CPP_MPI
     1846    CALL MPI_REDUCE(VarIn,VarOut,nb,MPI_REAL_LMDZ,MPI_MAX,mpi_master,COMM_LMDZ_PHY,ierr)
     1847#endif
     1848       
     1849  END SUBROUTINE reduce_max_mpi_rgen
    18071850
    18081851
Note: See TracChangeset for help on using the changeset viewer.