From 2f3616de09b93f7d0fe2c18f306ed3849682b5f1 Mon Sep 17 00:00:00 2001 From: ajocksch Date: Thu, 27 Sep 2018 10:10:39 +0200 Subject: [PATCH 1/3] WIP: correct programming environment required --- .../libraries/io/netcdf_compile_run.py | 56 +++++++++++++++++-- 1 file changed, 51 insertions(+), 5 deletions(-) diff --git a/cscs-checks/libraries/io/netcdf_compile_run.py b/cscs-checks/libraries/io/netcdf_compile_run.py index 5991360947..ff27a45ab5 100644 --- a/cscs-checks/libraries/io/netcdf_compile_run.py +++ b/cscs-checks/libraries/io/netcdf_compile_run.py @@ -18,15 +18,24 @@ def __init__(self, lang, linkage): self.linkage = linkage self.descr = lang_names[lang] + ' NetCDF ' + linkage.capitalize() self.valid_systems = ['daint:gpu', 'daint:mc', - 'dom:gpu', 'dom:mc'] - self.valid_prog_environs = ['PrgEnv-cray', 'PrgEnv-gnu', - 'PrgEnv-intel', 'PrgEnv-pgi'] + 'dom:gpu', 'dom:mc', 'kesch:cn'] + if self.current_system.name in ['daint', 'dom']: + self.valid_prog_environs = ['PrgEnv-cray', 'PrgEnv-gnu', + 'PrgEnv-intel', 'PrgEnv-pgi'] + elif self.current_system.name in ['kesch']: + if lang == 'f90': + self.valid_prog_environs = ['PrgEnv-pgi'] + else: + self.valid_prog_environs = ['PrgEnv-cray', 'PrgEnv-pgi'] self.sourcesdir = os.path.join(self.current_system.resourcesdir, 'netcdf') self.build_system = 'SingleSource' - self.build_system.ldflags = ['-%s' % linkage] self.sourcepath = 'netcdf_read_write.' + lang - self.modules = ['cray-netcdf'] + if self.current_system.name in ['daint', 'dom']: + self.modules = ['cray-netcdf'] + elif self.current_system.name in ['kesch']: + pass + self.num_tasks = 1 self.num_tasks_per_node = 1 self.sanity_patterns = sn.assert_found(r'SUCCESS', self.stdout) @@ -35,6 +44,43 @@ def __init__(self, lang, linkage): self.tags = {'production'} def setup(self, partition, environ, **job_opts): + if (environ.name == 'PrgEnv-cray'): + self.modules = ['netcdf/4.4.1.1-gmvolf-17.02', + 'netcdf-c++/4.3.0-gmvolf-17.02', + 'netcdf-fortran/4.4.4-gmvolf-17.02' + ] + self.build_system.ldflags = ['-I$EBROOTNETCDF/include', + '-I$EBROOTNETCDFMINCPLUSPLUS/include', + '-I$EBROOTNETCDFMINFORTRAN/include', + '-L$EBROOTNETCDF/lib', + '-L$EBROOTNETCDFMINCPLUSPLUS/lib', + '-L$EBROOTNETCDFMINFORTRAN/lib', + '-L$EBROOTNETCDF/lib64', + '-L$EBROOTNETCDFMINCPLUSPLUS/lib64', + '-L$EBROOTNETCDFMINFORTRAN/lib64', + '-lnetcdf', + '-lnetcdf_c++4', + '-lnetcdff' + ] + elif (environ.name == 'PrgEnv-pgi'): + self.modules = ['pgi/17.10-gcc-5.4.0-2.26', 'netcdf/4.6.1-pgi-17.10-gcc-5.4.0-2.26', + 'netcdf-c++/4.3.0-pgi-17.10-gcc-5.4.0-2.26', + 'netcdf-fortran/4.4.4-pgi-17.10-gcc-5.4.0-2.26', + ] + self.build_system.ldflags = ['-I$EBROOTNETCDF/include', + '-I$EBROOTNETCDFMINCPLUSPLUS/include', + '-I$EBROOTNETCDFMINFORTRAN/include', + '-L$EBROOTNETCDF/lib', + '-L$EBROOTNETCDFMINCPLUSPLUS/lib', + '-L$EBROOTNETCDFMINFORTRAN/lib', + '-L$EBROOTNETCDF/lib64', + '-L$EBROOTNETCDFMINCPLUSPLUS/lib64', + '-L$EBROOTNETCDFMINFORTRAN/lib64', + '-lnetcdf', + '-lnetcdf_c++4', + '-lnetcdff' + ] + # NOTE: Workaround to fix static linking for C++ with PrgEnv-pgi if (environ.name == 'PrgEnv-pgi' and self.lang == 'cpp'and From 8ce908f5070d37e01801e9fb5e84e5e5da19ab6d Mon Sep 17 00:00:00 2001 From: ajocksch Date: Thu, 27 Sep 2018 13:14:48 +0200 Subject: [PATCH 2/3] netcdf final; inconsistency in PrgEnv-... --- .../libraries/io/netcdf_compile_run.py | 25 +++---------------- 1 file changed, 4 insertions(+), 21 deletions(-) diff --git a/cscs-checks/libraries/io/netcdf_compile_run.py b/cscs-checks/libraries/io/netcdf_compile_run.py index ff27a45ab5..3d4ab1ed36 100644 --- a/cscs-checks/libraries/io/netcdf_compile_run.py +++ b/cscs-checks/libraries/io/netcdf_compile_run.py @@ -24,9 +24,10 @@ def __init__(self, lang, linkage): 'PrgEnv-intel', 'PrgEnv-pgi'] elif self.current_system.name in ['kesch']: if lang == 'f90': - self.valid_prog_environs = ['PrgEnv-pgi'] + self.valid_prog_environs = ['PrgEnv-pgi-nompi'] else: - self.valid_prog_environs = ['PrgEnv-cray', 'PrgEnv-pgi'] + self.valid_prog_environs = ['PrgEnv-cray-nompi', + 'PrgEnv-pgi-nompi'] self.sourcesdir = os.path.join(self.current_system.resourcesdir, 'netcdf') self.build_system = 'SingleSource' @@ -44,7 +45,7 @@ def __init__(self, lang, linkage): self.tags = {'production'} def setup(self, partition, environ, **job_opts): - if (environ.name == 'PrgEnv-cray'): + if (environ.name == 'PrgEnv-cray-nompi'): self.modules = ['netcdf/4.4.1.1-gmvolf-17.02', 'netcdf-c++/4.3.0-gmvolf-17.02', 'netcdf-fortran/4.4.4-gmvolf-17.02' @@ -62,24 +63,6 @@ def setup(self, partition, environ, **job_opts): '-lnetcdf_c++4', '-lnetcdff' ] - elif (environ.name == 'PrgEnv-pgi'): - self.modules = ['pgi/17.10-gcc-5.4.0-2.26', 'netcdf/4.6.1-pgi-17.10-gcc-5.4.0-2.26', - 'netcdf-c++/4.3.0-pgi-17.10-gcc-5.4.0-2.26', - 'netcdf-fortran/4.4.4-pgi-17.10-gcc-5.4.0-2.26', - ] - self.build_system.ldflags = ['-I$EBROOTNETCDF/include', - '-I$EBROOTNETCDFMINCPLUSPLUS/include', - '-I$EBROOTNETCDFMINFORTRAN/include', - '-L$EBROOTNETCDF/lib', - '-L$EBROOTNETCDFMINCPLUSPLUS/lib', - '-L$EBROOTNETCDFMINFORTRAN/lib', - '-L$EBROOTNETCDF/lib64', - '-L$EBROOTNETCDFMINCPLUSPLUS/lib64', - '-L$EBROOTNETCDFMINFORTRAN/lib64', - '-lnetcdf', - '-lnetcdf_c++4', - '-lnetcdff' - ] # NOTE: Workaround to fix static linking for C++ with PrgEnv-pgi if (environ.name == 'PrgEnv-pgi' and From 27bee9e00d9e991d9b391a2f541866a88e0746b1 Mon Sep 17 00:00:00 2001 From: Vasileios Karakasis Date: Tue, 9 Oct 2018 10:11:38 +0200 Subject: [PATCH 3/3] Fine-tune NetCDF test for Daint/Dom/Kesch --- .../libraries/io/netcdf_compile_run.py | 49 +++++++++---------- 1 file changed, 24 insertions(+), 25 deletions(-) diff --git a/cscs-checks/libraries/io/netcdf_compile_run.py b/cscs-checks/libraries/io/netcdf_compile_run.py index 3d4ab1ed36..2f9810ef5b 100644 --- a/cscs-checks/libraries/io/netcdf_compile_run.py +++ b/cscs-checks/libraries/io/netcdf_compile_run.py @@ -22,20 +22,18 @@ def __init__(self, lang, linkage): if self.current_system.name in ['daint', 'dom']: self.valid_prog_environs = ['PrgEnv-cray', 'PrgEnv-gnu', 'PrgEnv-intel', 'PrgEnv-pgi'] - elif self.current_system.name in ['kesch']: - if lang == 'f90': - self.valid_prog_environs = ['PrgEnv-pgi-nompi'] - else: - self.valid_prog_environs = ['PrgEnv-cray-nompi', - 'PrgEnv-pgi-nompi'] + elif self.current_system.name == 'kesch': + self.valid_prog_environs = ['PrgEnv-pgi-nompi'] + if lang != 'f90': + self.valid_prog_environs += ['PrgEnv-cray-nompi'] + self.sourcesdir = os.path.join(self.current_system.resourcesdir, 'netcdf') self.build_system = 'SingleSource' + self.build_system.ldflags = ['-%s' % linkage] self.sourcepath = 'netcdf_read_write.' + lang if self.current_system.name in ['daint', 'dom']: self.modules = ['cray-netcdf'] - elif self.current_system.name in ['kesch']: - pass self.num_tasks = 1 self.num_tasks_per_node = 1 @@ -45,28 +43,29 @@ def __init__(self, lang, linkage): self.tags = {'production'} def setup(self, partition, environ, **job_opts): - if (environ.name == 'PrgEnv-cray-nompi'): + if (self.current_system.name == 'kesch' and + environ.name == 'PrgEnv-cray-nompi'): self.modules = ['netcdf/4.4.1.1-gmvolf-17.02', 'netcdf-c++/4.3.0-gmvolf-17.02', - 'netcdf-fortran/4.4.4-gmvolf-17.02' - ] - self.build_system.ldflags = ['-I$EBROOTNETCDF/include', - '-I$EBROOTNETCDFMINCPLUSPLUS/include', - '-I$EBROOTNETCDFMINFORTRAN/include', - '-L$EBROOTNETCDF/lib', - '-L$EBROOTNETCDFMINCPLUSPLUS/lib', - '-L$EBROOTNETCDFMINFORTRAN/lib', - '-L$EBROOTNETCDF/lib64', - '-L$EBROOTNETCDFMINCPLUSPLUS/lib64', - '-L$EBROOTNETCDFMINFORTRAN/lib64', - '-lnetcdf', - '-lnetcdf_c++4', - '-lnetcdff' - ] + 'netcdf-fortran/4.4.4-gmvolf-17.02'] + self.build_system.cppflags = [ + '-I$EBROOTNETCDF/include', + '-I$EBROOTNETCDFMINCPLUSPLUS/include', + '-I$EBROOTNETCDFMINFORTRAN/include' + ] + self.build_system.ldflags = [ + '-L$EBROOTNETCDF/lib', + '-L$EBROOTNETCDFMINCPLUSPLUS/lib', + '-L$EBROOTNETCDFMINFORTRAN/lib', + '-L$EBROOTNETCDF/lib64', + '-L$EBROOTNETCDFMINCPLUSPLUS/lib64', + '-L$EBROOTNETCDFMINFORTRAN/lib64', + '-lnetcdf', '-lnetcdf_c++4', '-lnetcdff' + ] # NOTE: Workaround to fix static linking for C++ with PrgEnv-pgi if (environ.name == 'PrgEnv-pgi' and - self.lang == 'cpp'and + self.lang == 'cpp' and self.linkage == 'static'): self.build_system.ldflags += ['-lstdc++']