New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
batch-ifort_athena_xios_omp in branches/2017/wrk_OMP_test_for_Silvia/NEMOGCM/SETTE/BATCH_TEMPLATE – NEMO

source: branches/2017/wrk_OMP_test_for_Silvia/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-ifort_athena_xios_omp @ 8279

Last change on this file since 8279 was 8279, checked in by mocavero, 7 years ago

Implementation of OMP coarse-grained parallelization on ZDF new package

  • Property svn:executable set to *
File size: 2.4 KB
Line 
1#!/bin/bash
2#!
3#BSUB -q poe_short
4#BSUB -n TOTAL_NPROCS
5#BSUB -a poe
6#BSUB -R "span[ptile=NPROC_NODE]"
7#BSUB -J NEMO_SETTE
8#BSUB -o poe.stdout.%J
9#BSUB -e poe.stderr.%J
10#BSUB -x
11
12 
13
14###############################################################
15# Test specific settings. Do not hand edit these lines; the fcm_job.sh script will set these
16# (via sed operating on this template job file).
17#
18  OCEANCORES=NPROCS
19  XIOS_NUMPROCS=NXIOPROCS
20  export SETTE_DIR=DEF_SETTE_DIR
21
22  export MP_TASK_AFFINITY=mcm
23  export OMP_NUM_THREADS=OMP_NTHR
24  export OMP_STACKSIZE="500M"
25
26###############################################################
27#
28# set up mpp computing environment
29#
30# Local settings for machine IBM Power6 (VARGAS at IDRIS France)
31#
32
33# export MPIRUN="mpirun -n $OCEANCORES"
34
35module load  INTEL/intel_xe_2013 NETCDF/netcdf-4.3_parallel NETCDF/parallel-netcdf-1.3.1 HDF5/hdf5-1.8.11_parallel
36export MPIRUN="mpirun.lsf"
37
38export LD_LIBRARY_PATH=${XIOS}/lib:${LD_LIBRARY_PATH}
39
40XIOS_SERVER_PATHNAME="${XIOS}/bin/xios_server.exe"
41
42#
43# load sette functions (only post_test_tidyup needed)
44#
45  . ${SETTE_DIR}/all_functions.sh
46
47
48# Don't remove neither change the following line
49# BODY
50
51#
52# These variables are needed by post_test_tidyup function in all_functions.sh
53#
54  export EXE_DIR=DEF_EXE_DIR
55  export INPUT_DIR=DEF_INPUT_DIR
56  export CONFIG_DIR=DEF_CONFIG_DIR
57  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION
58  export NEW_CONF=DEF_NEW_CONF
59  export CMP_NAM=DEF_CMP_NAM
60  export TEST_NAME=DEF_TEST_NAME
61#
62# end of set up
63
64
65###############################################################
66#
67# change to the working directory
68#
69cd ${EXE_DIR}
70
71#
72  echo Running on host `hostname`
73  echo Time is `date`
74  echo Directory is `pwd`
75#
76#  Run the parallel MPI executable
77#
78#  echo "Running time ${MPIRUN} " $OCEANCORES " ./opa"
79#
80
81  if [ MPI_FLAG == "yes" ]; then
82     if [ $XIOS_NUMPROCS -eq 0 ]; then
83       time ${MPIRUN} ./opa
84     else
85
86       export MP_PGMMODEL=mpmd
87       export MP_CMDFILE=xioscmdfile
88       rm xioscmdfile &> /dev/null
89       touch xioscmdfile
90       k=0
91       while (( k < $OCEANCORES )) ; do
92          echo ./opa >> xioscmdfile
93          k=`expr $k + 1`
94       done
95       k=0
96       while (( k < $XIOS_NUMPROCS )) ; do
97          echo $XIOS_SERVER_PATHNAME >> xioscmdfile
98          k=`expr $k + 1`
99       done
100
101       time ${MPIRUN}
102     fi
103  else
104     time ./opa
105  fi
106#
107  post_test_tidyup
108
109# END_BODY
110# Don't remove neither change the previous line
111
112  exit
Note: See TracBrowser for help on using the repository browser.