From dd9efb2960d73fd0df77f3a2cf4f3ddffb97f01b Mon Sep 17 00:00:00 2001 From: blackgaryc Date: Sun, 17 Jul 2022 10:32:49 +0800 Subject: [PATCH 1/3] update mfem --- .../openeuler-kgc-9-openmpi4-mfem-4.4.def | 32 +++++++++++++++ package/hypre/2.25.0/install.sh | 8 ++++ package/metis/4.0.3/install.sh | 6 +++ package/mfem/4.4/install.sh | 2 +- templates/mfem/4.4/data.mfem.arm.cpu.config | 39 +++++++++++++++++++ 5 files changed, 86 insertions(+), 1 deletion(-) create mode 100644 container/openeuler-kgc-9-openmpi4-mfem-4.4.def create mode 100644 package/hypre/2.25.0/install.sh create mode 100644 package/metis/4.0.3/install.sh create mode 100644 templates/mfem/4.4/data.mfem.arm.cpu.config diff --git a/container/openeuler-kgc-9-openmpi4-mfem-4.4.def b/container/openeuler-kgc-9-openmpi4-mfem-4.4.def new file mode 100644 index 0000000..537918c --- /dev/null +++ b/container/openeuler-kgc-9-openmpi4-mfem-4.4.def @@ -0,0 +1,32 @@ +BootStrap: docker +From: openeuler/openeuler + +%environment + source /etc/profile || true + cd /hpcrunner + source env.sh + +%post + # Install the necessary development environment + yum install -y environment-modules git dmidecode pciutils wget vim make + # install network package + yum install -y tcsh tcl lsof tk bc + source /etc/profile || true + git config --global http.sslVerify false + git clone https://gitee.com/openeuler/hpcrunner + cd hpcrunner + source ./init.sh + ./jarvis -i + # Switch config + ./jarvis -use templates/mfem/4.4/data.mfem.arm.cpu.config + # install dependency + ./jarvis -dp + # build hpc + ./jarvis -b + # run hpc + ./jarvis -r + # clean download directory + rm -rf downloads + +%labels + Author blackgaryc \ No newline at end of file diff --git a/package/hypre/2.25.0/install.sh b/package/hypre/2.25.0/install.sh new file mode 100644 index 0000000..01a6e16 --- /dev/null +++ b/package/hypre/2.25.0/install.sh @@ -0,0 +1,8 @@ +. ${DOWNLOAD_TOOL} -u https://github.com/hypre-space/hypre/archive/refs/tags/v2.25.0.tar.gz +cd ${JARVIS_TMP} +rm -rf hypre-2.25.0 +tar -xf ${JARVIS_DOWNLOAD}/v2.25.0.tar.gz +cd hypre-2.25.0/src +./configure --disable-fortran --prefix=$1 +make -j +make install diff --git a/package/metis/4.0.3/install.sh b/package/metis/4.0.3/install.sh new file mode 100644 index 0000000..97621ff --- /dev/null +++ b/package/metis/4.0.3/install.sh @@ -0,0 +1,6 @@ +. ${DOWNLOAD_TOOL} -u http://coin-or-tools.github.io/ThirdParty-Metis/metis-4.0.3.tar.gz +cd ${JARVIS_TMP} +rm -rf metis-4.0.3 +tar -xf ${JARVIS_DOWNLOAD}/metis-4.0.3.tar.gz +cd metis-4.0.3 +make diff --git a/package/mfem/4.4/install.sh b/package/mfem/4.4/install.sh index 66ac7f6..4171802 100644 --- a/package/mfem/4.4/install.sh +++ b/package/mfem/4.4/install.sh @@ -7,5 +7,5 @@ rm -rf mfem-4.4 tar -xvf ${JARVIS_DOWNLOAD}/v4.4.tar.gz sed -i 's/>= MINSIGSTKSZ.*/;/' mfem-4.4/tests/unit/catch.hpp cd mfem-4.4 -make serial -j +make serial make install PREFIX=$1 \ No newline at end of file diff --git a/templates/mfem/4.4/data.mfem.arm.cpu.config b/templates/mfem/4.4/data.mfem.arm.cpu.config new file mode 100644 index 0000000..774cd5b --- /dev/null +++ b/templates/mfem/4.4/data.mfem.arm.cpu.config @@ -0,0 +1,39 @@ +[SERVER] +11.11.11.11 + +[DEPENDENCY] +module use ./software/modulefiles +module purge +./jarvis -install bisheng/2.1.0 com +module load bisheng2/2.1.0 +export CC=clang CXX=clang++ FC=flang +./jarvis -install hmpi/1.1.1 clang +module load hmpi1/1.1.1 +export CC=mpicc CXX=mpicxx FC=mpifort F77=mpifort +./jarvis -install hypre/2.25.0 bisheng+mpi +./jarvis -install metis/4.0.3 bisheng+mpi +ln -sf ${JARVIS_ROOT}/tmp/hypre-2.25.0 ${JARVIS_ROOT}/tmp/hypre +ln -sf ${JARVIS_ROOT}/tmp/metis-4.0.3 ${JARVIS_ROOT}/tmp/metis-4.0 +ln -sf ${JARVIS_ROOT}/tmp/hypre-2.25.0 ${JARVIS_ROOT}/tmp/hypre + +[ENV] +module purge +module use ${JARVIS_ROOT}/software/modulefiles +module load bisheng2/2.1.0 +export CC=clang CXX=clang++ FC=flang +module load openmpi4/4.1.2 +export CC=mpicc CXX=mpicxx FC=mpifort F77=mpifort + +[APP] +app_name = mfem +build_dir = ${JARVIS_ROOT} +binary_dir = +case_dir = + +[BUILD] +./jarvis -install mfem/4.4 gcc + +[RUN] +run = cd ${JARVIS_ROOT}/tmp/mfem-4.4 && make test OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 +binary = +nodes = 1 \ No newline at end of file -- Gitee From f48f222a7e8419a67ed67253badad081ea7bc690 Mon Sep 17 00:00:00 2001 From: blackgaryc Date: Tue, 26 Jul 2022 08:49:56 +0800 Subject: [PATCH 2/3] update --- ....def => openeuler-gcc9-hmpi1-mfem-4.4.def} | 8 ++--- .../openeuler-kgc-9-openmpi4-mfem-4.4.def | 32 ------------------- package/mfem/4.4/install.sh | 2 +- templates/mfem/4.4/data.mfem.amd.cpu.config | 25 +++++++++------ templates/mfem/4.4/data.mfem.arm.cpu.config | 19 +++++------ 5 files changed, 29 insertions(+), 57 deletions(-) rename container/{openeuler-gcc-9.3.0-mfem.def => openeuler-gcc9-hmpi1-mfem-4.4.def} (69%) delete mode 100644 container/openeuler-kgc-9-openmpi4-mfem-4.4.def diff --git a/container/openeuler-gcc-9.3.0-mfem.def b/container/openeuler-gcc9-hmpi1-mfem-4.4.def similarity index 69% rename from container/openeuler-gcc-9.3.0-mfem.def rename to container/openeuler-gcc9-hmpi1-mfem-4.4.def index b45e03f..f484a65 100644 --- a/container/openeuler-gcc-9.3.0-mfem.def +++ b/container/openeuler-gcc9-hmpi1-mfem-4.4.def @@ -8,11 +8,7 @@ From: openeuler/openeuler %post # Install the necessary development environment - yum install -y environment-modules git dmidecode pciutils wget vim - # Install base gcc - yum install -y gcc gcc-c++ gcc-gfortran glibc-devel make libgfortran - # install network package - yum install -y tcsh tcl lsof tk bc + yum install -y environment-modules git wget unzip make flex tar source /etc/profile || true git config --global http.sslVerify false git clone https://gitee.com/openeuler/hpcrunner @@ -28,7 +24,7 @@ From: openeuler/openeuler # run hpc ./jarvis -r # clean tmp directory - #rm -rf downloads tmp + rm -rf downloads %labels Author blackgaryc \ No newline at end of file diff --git a/container/openeuler-kgc-9-openmpi4-mfem-4.4.def b/container/openeuler-kgc-9-openmpi4-mfem-4.4.def deleted file mode 100644 index 537918c..0000000 --- a/container/openeuler-kgc-9-openmpi4-mfem-4.4.def +++ /dev/null @@ -1,32 +0,0 @@ -BootStrap: docker -From: openeuler/openeuler - -%environment - source /etc/profile || true - cd /hpcrunner - source env.sh - -%post - # Install the necessary development environment - yum install -y environment-modules git dmidecode pciutils wget vim make - # install network package - yum install -y tcsh tcl lsof tk bc - source /etc/profile || true - git config --global http.sslVerify false - git clone https://gitee.com/openeuler/hpcrunner - cd hpcrunner - source ./init.sh - ./jarvis -i - # Switch config - ./jarvis -use templates/mfem/4.4/data.mfem.arm.cpu.config - # install dependency - ./jarvis -dp - # build hpc - ./jarvis -b - # run hpc - ./jarvis -r - # clean download directory - rm -rf downloads - -%labels - Author blackgaryc \ No newline at end of file diff --git a/package/mfem/4.4/install.sh b/package/mfem/4.4/install.sh index 4171802..362b6bf 100644 --- a/package/mfem/4.4/install.sh +++ b/package/mfem/4.4/install.sh @@ -7,5 +7,5 @@ rm -rf mfem-4.4 tar -xvf ${JARVIS_DOWNLOAD}/v4.4.tar.gz sed -i 's/>= MINSIGSTKSZ.*/;/' mfem-4.4/tests/unit/catch.hpp cd mfem-4.4 -make serial +make parallel make install PREFIX=$1 \ No newline at end of file diff --git a/templates/mfem/4.4/data.mfem.amd.cpu.config b/templates/mfem/4.4/data.mfem.amd.cpu.config index 2c5c682..35bebd3 100644 --- a/templates/mfem/4.4/data.mfem.amd.cpu.config +++ b/templates/mfem/4.4/data.mfem.amd.cpu.config @@ -7,28 +7,35 @@ set -x ./jarvis -install gcc/9.3.0 com module purge module use ./software/modulefiles -module load gcc/9.3.0 +module load gcc9/9.3.0 export CC=`which gcc` export CXX=`which g++` export FC=`which gfortran` +./jarvis -install hmpi/1.1.1 gcc +module load hmpi1/1.1.1 +export CC=mpicc CXX=mpicxx FC=mpifort F77=mpifort +./jarvis -install hypre/2.25.0 gcc+mpi +./jarvis -install metis/4.0.3 gcc+mpi +ln -sf ${JARVIS_TMP}/hypre-2.25.0 ${JARVIS_TMP}/hypre +ln -sf ${JARVIS_TMP}/metis-4.0.3 ${JARVIS_TMP}/metis-4.0 + [ENV] module purge module use ${JARVIS_ROOT}/software/modulefiles -module load gcc/9.3.0 -export CC=`which gcc` -export CXX=`which g++` -export FC=`which gfortran` +module load gcc9/9.3.0 +module load hmpi1/1.1.1 +export CC=mpicc CXX=mpicxx FC=mpifort F77=mpifort [APP] app_name = mfem -build_dir = ${JARVIS_ROOT} +build_dir = ${JARVIS_TMP}/mfem-4.4 binary_dir = -case_dir = +case_dir = ${JARVIS_TMP}/mfem-4.4 [BUILD] -./jarvis -install mfem/4.4 gcc +cd ${JARVIS_ROOT} && ./jarvis -install mfem/4.4 gcc+mpi [RUN] -run = cd ${JARVIS_ROOT}/tmp/mfem-4.4 && make test +run = make test OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 binary = nodes = 1 diff --git a/templates/mfem/4.4/data.mfem.arm.cpu.config b/templates/mfem/4.4/data.mfem.arm.cpu.config index 774cd5b..17c83d5 100644 --- a/templates/mfem/4.4/data.mfem.arm.cpu.config +++ b/templates/mfem/4.4/data.mfem.arm.cpu.config @@ -2,8 +2,8 @@ 11.11.11.11 [DEPENDENCY] -module use ./software/modulefiles module purge +module use ./software/modulefiles ./jarvis -install bisheng/2.1.0 com module load bisheng2/2.1.0 export CC=clang CXX=clang++ FC=flang @@ -12,28 +12,29 @@ module load hmpi1/1.1.1 export CC=mpicc CXX=mpicxx FC=mpifort F77=mpifort ./jarvis -install hypre/2.25.0 bisheng+mpi ./jarvis -install metis/4.0.3 bisheng+mpi -ln -sf ${JARVIS_ROOT}/tmp/hypre-2.25.0 ${JARVIS_ROOT}/tmp/hypre -ln -sf ${JARVIS_ROOT}/tmp/metis-4.0.3 ${JARVIS_ROOT}/tmp/metis-4.0 -ln -sf ${JARVIS_ROOT}/tmp/hypre-2.25.0 ${JARVIS_ROOT}/tmp/hypre +ln -sf ${JARVIS_TMP}/hypre-2.25.0 ${JARVIS_TMP}/hypre +ln -sf ${JARVIS_TMP}/metis-4.0.3 ${JARVIS_TMP}/metis-4.0 [ENV] module purge module use ${JARVIS_ROOT}/software/modulefiles module load bisheng2/2.1.0 export CC=clang CXX=clang++ FC=flang -module load openmpi4/4.1.2 +module load hmpi1/1.1.1 export CC=mpicc CXX=mpicxx FC=mpifort F77=mpifort [APP] app_name = mfem -build_dir = ${JARVIS_ROOT} +build_dir = ${JARVIS_TMP}/mfem-4.4 binary_dir = -case_dir = +case_dir = ${JARVIS_TMP}/mfem-4.4 [BUILD] -./jarvis -install mfem/4.4 gcc +cd ${JARVIS_ROOT} && ./jarvis -install mfem/4.4 bisheng+mpi +# clang not suport this option +sed -i "s/-march=native/''/g" ${JARVIS_TMP}/mfem-4.4/miniapps/performance/makefile [RUN] -run = cd ${JARVIS_ROOT}/tmp/mfem-4.4 && make test OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 +run = make test OMPI_ALLOW_RUN_AS_ROOT=1 OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 binary = nodes = 1 \ No newline at end of file -- Gitee From 62d21afbd418e6873573c3c430b686d53032f8f7 Mon Sep 17 00:00:00 2001 From: blackgaryc Date: Tue, 26 Jul 2022 14:56:41 +0800 Subject: [PATCH 3/3] update --- ...hmpi1-mfem-4.4.def => openeuler-bisheng2-hmpi1-mfem-4.4.def} | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename container/{openeuler-gcc9-hmpi1-mfem-4.4.def => openeuler-bisheng2-hmpi1-mfem-4.4.def} (91%) diff --git a/container/openeuler-gcc9-hmpi1-mfem-4.4.def b/container/openeuler-bisheng2-hmpi1-mfem-4.4.def similarity index 91% rename from container/openeuler-gcc9-hmpi1-mfem-4.4.def rename to container/openeuler-bisheng2-hmpi1-mfem-4.4.def index f484a65..74457ec 100644 --- a/container/openeuler-gcc9-hmpi1-mfem-4.4.def +++ b/container/openeuler-bisheng2-hmpi1-mfem-4.4.def @@ -16,7 +16,7 @@ From: openeuler/openeuler source ./init.sh ./jarvis -i # Switch config - ./jarvis -use templates/mfem/4.4/data.mfem.amd.cpu.config + ./jarvis -use templates/mfem/4.4/data.mfem.arm.cpu.config # install dependency ./jarvis -dp # build hpc -- Gitee