- Timestamp:
- 06/18/12 17:21:40 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/libIGCM/libIGCM_sys/libIGCM_sys_titane.ksh
r686 r687 1709 1709 unset MPI_PLACING_MODE 1710 1710 1711 # add module load nb of threads for core placement 1712 (( max_omp = 0 )) 1713 1714 for comp in ${config_ListOfComponents[*]} ; do 1715 eval ExeNameIn=\${config_Executable_${comp}[0]} 1716 eval ExeNameOut=\${config_Executable_${comp}[1]} 1717 1718 # Only if we really have an executable for the component : 1719 if ( [ "X${ExeNameOut}" != X\"\" ] && [ "X${comp}" != "XCPL" ] && [ "X${ExeNameOut}" != "Xinca.dat" ] ) ; then 1720 eval comp_proc_omp_loc=\${${comp}_PROC_OMP} 1721 if [ ${comp_proc_omp_loc} -gt ${max_omp} ] ; then 1722 (( max_omp = comp_proc_omp_loc )) 1723 fi 1724 fi 1725 done 1726 1727 ( [ X${max_omp} = X4 ] || [ X${max_omp} = X8 ] ) && { module load openmp/${max_omp}thds ; IGCM_debug_Print 1 "module load openmp/${max_omp}thds" ; } 1728 1711 1729 IGCM_debug_PopStack "IGCM_sys_activ_variables" 1712 1730 } … … 1743 1761 typeset node_num_current node_current comp_proc_mpi_loc comp_proc_omp_loc 1744 1762 typeset num_corempi nombre_restant_node nombre_restant_comp 1763 typeset IGCM_OMP 1745 1764 1746 1765 if [ ! -f ${SUBMIT_DIR}/Job_${config_UserChoices_JobName} ] ; then … … 1952 1971 fi 1953 1972 1954 else # Only one executable. launch it. 1973 else # Only one executable. launch it after verifications. test done with : 1974 # Job : 1975 # #MSUB -n 8 # reservation des processeurs pour le job 1976 # #MSUB -N 4 # reservation des nodes pour le job 1977 # BATCH_NUM_PROC_TOT=32 1978 # 1979 # config.card : 1980 # ATM= (gcm.e, lmdz.x, 8MPI, 4OMP) 1955 1981 1956 1982 for comp in ${config_ListOfComponents[*]} ; do … … 1961 1987 if ( [ "X${ExeNameOut}" != X\"\" ] && [ "X${ExeNameOut}" != "Xinca.dat" ] ) ; then 1962 1988 1989 IGCM_OMP=1 1990 1963 1991 if ( ${OK_PARA_OMP} ) ; then 1964 1992 eval comp_proc_omp_loc=\${${comp}_PROC_OMP} 1965 1993 export OMP_NUM_THREADS=${comp_proc_omp_loc} 1994 IGCMG_OMP=${comp_proc_omp_loc} 1966 1995 fi 1967 1996 if ( ${OK_PARA_MPI} ) ; then 1968 1997 eval comp_proc_mpi_loc=\${${comp}_PROC_MPI} 1998 # Check if BATCH_NUM_PROC_TOT = (8*BRIDGE_MSUB_NNODE) 8 because we have 8 cores per node 1999 (( VERIF_BATCH_NUM_PROC_TOT = 8 * BRIDGE_MSUB_NNODE )) 2000 if ( [ ${VERIF_BATCH_NUM_PROC_TOT} -ne ${BATCH_NUM_PROC_TOT} ] ) ; then 2001 IGCM_debug_Print 1 "sys Titane : BATCH_NUM_PROC_TOT <> 8 * BRIDGE_MSUB_NNODE : ${BATCH_NUM_PROC_TOT} <> 8 * ${BRIDGE_MSUB_NNODE} " 2002 IGCM_debug_Print 1 "sys Titane : Check #MSUB -N xx into Job" 2003 IGCM_debug_Exit "IGCM_sys_build_execution_scripts" 2004 fi 2005 # Check if BATCH_NUM_PROC_TOT = (OMP_NUM_THREADS*BRIDGE_MSUB_NPROC) 2006 (( VERIF_BATCH_NUM_PROC_TOT = IGCMG_OMP * BRIDGE_MSUB_NPROC )) 2007 if ( [ ${VERIF_BATCH_NUM_PROC_TOT} -ne ${BATCH_NUM_PROC_TOT} ] ) ; then 2008 IGCM_debug_Print 1 "sys Titane : BATCH_NUM_PROC_TOT <> ${comp}_PROC_OMP * BRIDGE_MSUB_NPROC : ${BATCH_NUM_PROC_TOT} <> ${IGCMG_OMP} * ${BRIDGE_MSUB_NPROC} " 2009 IGCM_debug_Print 1 "sys Titane : Check #MSUB -n xx into Job" 2010 IGCM_debug_Exit "IGCM_sys_build_execution_scripts" 2011 fi 1969 2012 # Default : mpirun used if nb_proc gt 1 1970 2013 # pour sortie out/err par process ? more test required … … 1972 2015 EXECUTION="${HOST_MPIRUN_COMMAND} -np ${comp_proc_mpi_loc} ./${ExeNameOut}" 1973 2016 else 2017 # Check if BATCH_NUM_PROC_TOT = IGCMG_OMP 2018 if ( [ ${IGCM_OMP} -ne ${BATCH_NUM_PROC_TOT} ] ) ; then 2019 IGCM_debug_Print 1 "sys Titane : BATCH_NUM_PROC_TOT <> ${comp}_PROC_OMP : ${BATCH_NUM_PROC_TOT} <> ${BRIDGE_MSUB_NPROC} " 2020 IGCM_debug_Print 1 "sys Titane : Check #MSUB -n xx into Job" 2021 IGCM_debug_Exit "IGCM_sys_build_execution_scripts" 2022 fi 1974 2023 # Default : mpirun is NOT used if nb_proc eq 1 1975 2024 # pour sortie out/err par process ? more test required 1976 2025 # echo "./${ExeNameOut} > out_${ExeNameOut}.out 2>out_${ExeNameOut}.err" >> script_${ExeNameOut}.ksh 1977 EXECUTION=" time ./${ExeNameOut}"2026 EXECUTION="/usr/bin/time ./${ExeNameOut}" 1978 2027 fi 1979 2028 fi
Note: See TracChangeset
for help on using the changeset viewer.