Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide support for Livermore Computing (LC) #1367

Merged
merged 10 commits into from
May 23, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions cime/config/acme/machines/config_batch.xml
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,29 @@
<directive default="/bin/bash" > -S {{ shell }}</directive>
</directives>
</batch_system>

<!-- for cab llnl -->
<batch_system type="lc_slurm">
<batch_submit>msub</batch_submit>
<batch_directive>#MSUB</batch_directive>
<jobid_pattern>(\d+)$</jobid_pattern>
<depend_string> -l depend=jobid</depend_string>
<walltime_format>%H:%M:%S</walltime_format>
<directives>
<directive>-V</directive>
<directive>-q {{ job_queue }}</directive>
<directive>-N {{ job_id }}</directive>
<directive>-l nodes={{ num_nodes }}:ppn={{ tasks_per_node }}</directive>
<directive>-l walltime={{ job_wallclock_time }}</directive>
<directive>-o {{ output_error_path }}.out</directive>
<directive>-e {{ output_error_path }}.err</directive>
<directive>-m be</directive>
<directive> -A {{ project }} </directive>
</directives>
<queues>
<queue walltimemax="01:00:00" jobmin="1" jobmax="4320" default="true">pbatch</queue>
</queues>
</batch_system>

<batch_system type="slurm" >
<batch_query>squeue</batch_query>
Expand Down
44 changes: 44 additions & 0 deletions cime/config/acme/machines/config_compilers.xml
Original file line number Diff line number Diff line change
Expand Up @@ -749,6 +749,50 @@ for mct, etc.
<ADD_CPPDEFS MODEL="pop"> -D_USE_FLOW_CONTROL </ADD_CPPDEFS>
</compiler>

<compiler COMPILER="pgi" MACH="cab">
<NETCDF_PATH>/usr/local/tools/netcdf-pgi-4.1.3</NETCDF_PATH>
<MPI_PATH>/usr/local/tools/mvapich2-pgi-1.7/</MPI_PATH>
<MPI_LIB_NAME> mpich</MPI_LIB_NAME>
<ADD_CPPDEFS> -DNO_SHR_VMATH -DCNL </ADD_CPPDEFS>
<ADD_SLIBS>$(shell /usr/local/tools/netcdf-pgi-4.1.3/bin/nc-config --flibs)</ADD_SLIBS>
<ADD_LDFLAGS> -Wl,-rpath /usr/local/tools/netcdf-pgi-4.1.3/lib -llapack -lblas</ADD_LDFLAGS>
</compiler>

<compiler COMPILER="intel" MACH="cab">
<ADD_CFLAGS DEBUG="FALSE"> -O2 </ADD_CFLAGS>
<ADD_FFLAGS DEBUG="FALSE"> -O2 </ADD_FFLAGS>
<NETCDF_PATH>/usr/local/tools/netcdf-intel-4.1.3</NETCDF_PATH>
<CONFIG_ARGS> --host=Linux </CONFIG_ARGS>
<MPI_PATH>/usr/local/tools/mvapich2-intel-2.1/</MPI_PATH>
<MPI_LIB_NAME> mpich</MPI_LIB_NAME>
<ADD_CPPDEFS> -DNO_SHR_VMATH -DCNL </ADD_CPPDEFS>
<ADD_FFLAGS DEBUG="TRUE"> -g -traceback -O0 -fpe0 -check all -check noarg_temp_created -ftrapuv </ADD_FFLAGS>
<ADD_SLIBS>$(shell /usr/local/tools/netcdf-intel-4.1.3/bin/nc-config --flibs)</ADD_SLIBS>
<ADD_LDFLAGS> -llapack -lblas</ADD_LDFLAGS>
</compiler>

<compiler COMPILER="pgi" MACH="syrah">
<NETCDF_PATH>/usr/local/tools/netcdf-pgi-4.1.3</NETCDF_PATH>
<MPI_PATH>/usr/local/tools/mvapich2-pgi-1.7/</MPI_PATH>
<MPI_LIB_NAME> mpich</MPI_LIB_NAME>
<ADD_CPPDEFS> -DNO_SHR_VMATH -DCNL </ADD_CPPDEFS>
<ADD_SLIBS>$(shell /usr/local/tools/netcdf-pgi-4.1.3/bin/nc-config --flibs)</ADD_SLIBS>
<ADD_LDFLAGS> -Wl,-rpath /usr/local/tools/netcdf-pgi-4.1.3/lib -llapack -lblas</ADD_LDFLAGS>
</compiler>

<compiler COMPILER="intel" MACH="syrah">
<ADD_CFLAGS DEBUG="FALSE"> -O2 </ADD_CFLAGS>
<ADD_FFLAGS DEBUG="FALSE"> -O2 </ADD_FFLAGS>
<NETCDF_PATH>/usr/local/tools/netcdf-intel-4.1.3</NETCDF_PATH>
<CONFIG_ARGS> --host=Linux </CONFIG_ARGS>
<MPI_PATH>/usr/local/tools/mvapich2-intel-2.1/</MPI_PATH>
<MPI_LIB_NAME> mpich</MPI_LIB_NAME>
<ADD_CPPDEFS> -DNO_SHR_VMATH -DCNL </ADD_CPPDEFS>
<ADD_FFLAGS DEBUG="TRUE"> -g -traceback -O0 -fpe0 -check all -check noarg_temp_created -ftrapuv </ADD_FFLAGS>
<ADD_SLIBS>$(shell /usr/local/tools/netcdf-intel-4.1.3/bin/nc-config --flibs)</ADD_SLIBS>
<ADD_LDFLAGS> -llapack -lblas</ADD_LDFLAGS>
</compiler>

<compiler MACH="oic2" COMPILER="gnu">
<NETCDF_PATH>/projects/cesm/devtools/netcdf-4.1.3-gcc4.8.1-mpich3.0.4/</NETCDF_PATH>
<ADD_SLIBS>-L/user/lib64 -llapack -lblas -lnetcdff </ADD_SLIBS>
Expand Down
112 changes: 89 additions & 23 deletions cime/config/acme/machines/config_machines.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1076,44 +1076,110 @@
</environment_variables>
</machine>

<machine MACH="sierra">
<DESC>LLNL Linux Cluster, Linux (pgi), 12 pes/node, batch system is Moab</DESC>
<machine MACH="cab">
<DESC>LLNL Linux Cluster, Linux (pgi), 16 pes/node, batch system is Slurm</DESC>
<COMPILERS>intel, pgi</COMPILERS>
<MPILIBS>mpich,mpi-serial</MPILIBS>
<RUNDIR>/p/lscratche/$CCSMUSER/ACME/$CASE/run</RUNDIR>
<EXEROOT>/p/lscratche/$CCSMUSER/$CASE/bld</EXEROOT>
<CIME_OUTPUT_ROOT>/p/lscratche/$USER</CIME_OUTPUT_ROOT>
<DIN_LOC_ROOT>/p/lscratchd/ma21/ccsm3data/inputdata</DIN_LOC_ROOT>
<DIN_LOC_ROOT_CLMFORC>/p/lscratchd/ma21/ccsm3data/inputdata/atm/datm7</DIN_LOC_ROOT_CLMFORC>
<DIN_LOC_ROOT>/usr/gdata/climdat/ccsm3data/inputdata</DIN_LOC_ROOT>
<DIN_LOC_ROOT_CLMFORC>/usr/gdata/climdat/ccsm3data/inputdata/atm/datm7</DIN_LOC_ROOT_CLMFORC>
<DOUT_S_ROOT>/p/lscratche/$CCSMUSER/archive/$CASE</DOUT_S_ROOT>
<DOUT_L_HTAR>FALSE</DOUT_L_HTAR>
<DOUT_L_MSROOT>UNSET</DOUT_L_MSROOT>
<BASELINE_ROOT>/p/lscratchd/$CCSMUSER/ccsm_baselines</BASELINE_ROOT>
<CCSM_CPRNC>/p/lscratchd/ma21/ccsm3data/tools/cprnc/cprnc</CCSM_CPRNC>
<OS>LINUX</OS>
<BATCHQUERY>mshow</BATCHQUERY>
<BATCHSUBMIT>msub</BATCHSUBMIT>
<BATCHREDIRECT></BATCHREDIRECT>
<SUPPORTED_BY>wlin -at- bnl.gov</SUPPORTED_BY>
<SUPPORTED_BY>bogenschutz1 -at- llnl.gov</SUPPORTED_BY>
<GMAKE_J>8</GMAKE_J>
<MAX_TASKS_PER_NODE>12</MAX_TASKS_PER_NODE>
<batch_system type="sierra_slurm" version="x.y">
<queues>
<queue jobmin="1" jobmax="9999" default="true">pbatch</queue>
</queues>
<walltimes>
<walltime default="true">walltime=01:00:00</walltime>
</walltimes>
</batch_system>
<mpirun mpilib="mpich">
<executable>srun</executable>
<arguments>
<arg name="num_nodes"> -N {{ num_nodes }}</arg>
</arguments>
<MAX_TASKS_PER_NODE>16</MAX_TASKS_PER_NODE>
<PES_PER_NODE>16</PES_PER_NODE>
<BATCH_SYSTEM>lc_slurm</BATCH_SYSTEM>
<SAVE_TIMING_DIR>/usr/gdata/climdat/timing_performance</SAVE_TIMING_DIR>
<mpirun mpilib="mpi-serial">
<executable></executable>
</mpirun>
<mpirun mpilib="default">
<executable>srun</executable>
</mpirun>
<module_system type="generic">
<cmd_path lang="sh">use</cmd_path>
<cmd_path lang="csh">use</cmd_path>
<init_path lang="csh">/usr/global/tools/dotkit/init.csh</init_path>
<init_path lang="sh">/usr/global/tools/dotkit/init.sh</init_path>
<modules compiler="pgi">
<command name="-q">pgi-14.3</command>
<command name="-q">mvapich2-pgi-1.7</command>
<command name="-q">netcdf-pgi-4.1.3</command>
</modules>
<modules compiler="intel">
<command name="-q">ic-14.0.211</command>
<command name="-q">mvapich2-intel-2.1</command>
<command name="-q">netcdf-intel-4.1.3</command>
</modules>
</module_system>
<environment_variables compiler="pgi">
<env name="NETCDF">/usr/local/tools/netcdf-pgi-4.1.3/</env>
<env name="PNETCDF_PATH" mpilib="!mpi-serial">/usr/local/tools/parallel-netcdf-pgi-1.6.1/</env>
</environment_variables>
<environment_variables compiler="intel">
<env name="NETCDF">/usr/local/tools/netcdf-intel-4.1.3/</env>
<env name="PNETCDF_PATH" mpilib="!mpi-serial">/usr/local/tools/parallel-netcdf-intel-1.6.1/</env>
</environment_variables>
</machine>

<machine MACH="syrah">
<DESC>LLNL Linux Cluster, Linux (pgi), 16 pes/node, batch system is Slurm</DESC>
<COMPILERS>intel, pgi</COMPILERS>
<MPILIBS>mpich,mpi-serial</MPILIBS>
<RUNDIR>/p/lscratche/$CCSMUSER/ACME/$CASE/run</RUNDIR>
<EXEROOT>/p/lscratche/$CCSMUSER/$CASE/bld</EXEROOT>
<CIME_OUTPUT_ROOT>/p/lscratche/$USER</CIME_OUTPUT_ROOT>
<DIN_LOC_ROOT>/usr/gdata/climdat/ccsm3data/inputdata</DIN_LOC_ROOT>
<DIN_LOC_ROOT_CLMFORC>/usr/gdata/climdat/ccsm3data/inputdata/atm/datm7</DIN_LOC_ROOT_CLMFORC>
<DOUT_S_ROOT>/p/lscratche/$CCSMUSER/archive/$CASE</DOUT_S_ROOT>
<DOUT_L_HTAR>FALSE</DOUT_L_HTAR>
<DOUT_L_MSROOT>UNSET</DOUT_L_MSROOT>
<BASELINE_ROOT>/p/lscratchd/$CCSMUSER/ccsm_baselines</BASELINE_ROOT>
<CCSM_CPRNC>/p/lscratchd/ma21/ccsm3data/tools/cprnc/cprnc</CCSM_CPRNC>
<OS>LINUX</OS>
<SUPPORTED_BY>bogenschutz1 -at- llnl.gov</SUPPORTED_BY>
<GMAKE_J>8</GMAKE_J>
<MAX_TASKS_PER_NODE>16</MAX_TASKS_PER_NODE>
<PES_PER_NODE>16</PES_PER_NODE>
<BATCH_SYSTEM>lc_slurm</BATCH_SYSTEM>
<SAVE_TIMING_DIR>/usr/gdata/climdat/timing_performance</SAVE_TIMING_DIR>
<mpirun mpilib="mpi-serial">
<executable></executable>
<executable></executable>
</mpirun>
<mpirun mpilib="default">
<executable>srun</executable>
</mpirun>
<module_system type="generic">
<cmd_path lang="sh">use</cmd_path>
<cmd_path lang="csh">use</cmd_path>
<init_path lang="csh">/usr/global/tools/dotkit/init.csh</init_path>
<init_path lang="sh">/usr/global/tools/dotkit/init.sh</init_path>
<modules compiler="pgi">
<command name="-q">pgi-14.3</command>
<command name="-q">mvapich2-pgi-1.7</command>
<command name="-q">netcdf-pgi-4.1.3</command>
</modules>
<modules compiler="intel">
<command name="-q">ic-14.0.211</command>
<command name="-q">mvapich2-intel-2.1</command>
<command name="-q">netcdf-intel-4.1.3</command>
</modules>
</module_system>
<environment_variables compiler="pgi">
<env name="NETCDF">/usr/local/tools/netcdf-pgi-4.1.3/</env>
<env name="PNETCDF_PATH" mpilib="!mpi-serial">/usr/local/tools/parallel-netcdf-pgi-1.6.1/</env>
</environment_variables>
<environment_variables compiler="intel">
<env name="NETCDF">/usr/local/tools/netcdf-intel-4.1.3/</env>
<env name="PNETCDF_PATH" mpilib="!mpi-serial">/usr/local/tools/parallel-netcdf-intel-1.6.1/</env>
</environment_variables>
</machine>

<machine MACH="mira">
Expand Down
27 changes: 10 additions & 17 deletions cime/scripts/lib/CIME/XML/env_mach_specific.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,9 @@ def load_modules(self, modules_to_load):
if (module_system == "module"):
self._load_module_modules(modules_to_load)
elif (module_system == "soft"):
self._load_soft_modules(modules_to_load)
elif (module_system == "dotkit"):
self._load_dotkit_modules(modules_to_load)
self._load_modules_generic(modules_to_load)
elif (module_system == "generic"):
self._load_modules_generic(modules_to_load)
elif (module_system == "none"):
self._load_none_modules(modules_to_load)
else:
Expand All @@ -112,7 +112,7 @@ def list_modules(self):
elif (module_system == "soft"):
# Does soft really not provide this capability?
return ""
elif (module_system == "dotkit"):
elif (module_system == "generic"):
return run_cmd_no_fail("%suse -lv" % source_cmd)
elif (module_system == "none"):
return ""
Expand Down Expand Up @@ -221,18 +221,14 @@ def _load_module_modules(self, modules_to_load):
"module command %s failed with message:\n%s"%(cmd,errout))
exec(py_module_code)

def _load_soft_modules(self, modules_to_load):
def _load_modules_generic(self, modules_to_load):
sh_init_cmd = self.get_module_system_init_path("sh")
sh_mod_cmd = self.get_module_system_cmd_path("sh")

# Some machines can set the environment
# variables using a script (such as /etc/profile.d/00softenv.sh
# on mira or /etc/profile.d/a_softenv.sh on blues)
# which load the new environment variables using softenv-load.

# Other machines need to run soft-dec.sh and evaluate the output,
# which may or may not have unresolved variables such as
# PATH=/soft/com/packages/intel/16/initial/bin:${PATH}
# Purpose is for environment management system that does not have
# a python interface and therefore can only determine what they
# do by running shell command and looking at the changes
# in the environment.

cmd = "source %s" % sh_init_cmd

Expand Down Expand Up @@ -279,10 +275,7 @@ def _load_soft_modules(self, modules_to_load):
if key in os.environ and key not in newenv:
del(os.environ[key])
else:
os.environ[key] = newenv[key]

def _load_dotkit_modules(self, _):
expect(False, "Not yet implemented")
os.environ[key] = newenv[key]

def _load_none_modules(self, modules_to_load):
"""
Expand Down
2 changes: 1 addition & 1 deletion cime/src/drivers/mct/cime_config/config_component.xml
Original file line number Diff line number Diff line change
Expand Up @@ -544,7 +544,7 @@
<entry id="BATCH_SYSTEM">
<type>char</type>
<default_value>none</default_value>
<valid_values>moab,pbs,lsf,slurm,cobalt,cobalt_theta,none</valid_values>
<valid_values>lc_slurm,moab,pbs,lsf,slurm,cobalt,cobalt_theta,none</valid_values>
<group>config_batch</group>
<file>env_batch.xml</file>
<desc>The batch system type to use for this machine.</desc>
Expand Down
2 changes: 2 additions & 0 deletions cime/src/externals/pio1/pio/pionfput_mod.F90.in
Original file line number Diff line number Diff line change
Expand Up @@ -697,9 +697,11 @@ contains
#endif
#endif
#ifdef _NETCDF
#ifdef _NETCDF4
case(pio_iotype_netcdf4p)
ierr=nf90_var_par_access(File%fh, varid, NF90_COLLECTIVE)
ierr = nf90_put_var(File%fh, varid, ival, start=int(pstart), count=int(pcount))
#endif
case(pio_iotype_netcdf, pio_iotype_netcdf4c)
! Only io proc 0 will do writing
if (Ios%io_rank == 0) then
Expand Down