Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
hopefully bigdft CI (work around an issue we identified, pending a fix)
[simgrid.git] / tools / jenkins / ci-bigdft.sh
1 #!/bin/sh
2
3 # Test this script locally as follows (rerun `docker pull simgrid/unstable` to get a fresh version).
4 # cd (simgrid)/tools/jenkins
5 # docker run -it --rm --volume `pwd`:/source simgrid/unstable /source/ci-bigdft.sh
6
7 set -ex
8
9 echo "XXXXXXXXXXXXXXXX Install APT dependencies"
10 SUDO="" # to ease the local testing
11 $SUDO apt-get -y update
12 $SUDO apt-get -y install python-is-python3 python3-setuptools libboost-dev libeigen3-dev
13 $SUDO apt-get -y install --only-upgrade ca-certificates
14
15 echo "XXXXXXXXXXXXXXXX build and test BigDFT (git version)"
16 git clone --depth=1 https://gitlab.com/l_sim/bigdft-suite.git
17 cd bigdft-suite
18
19 WORKSPACE=$PWD
20 mkdir build && cd build
21 export PATH=$PWD/simgrid-dev/smpi_script/bin/:$PATH
22 export LD_LIBRARY_PATH=$PWD/simgrid-dev/lib/:$LD_LIBRARY_PATH
23 export JHBUILD_RUN_AS_ROOT=1
24
25 #workaround issue with ntpoly 3.0.0
26 sed -i 's|repository type="tarball" name="ntpoly" href="https://github.com/william-dawson/NTPoly/archive/"|repository type="git" name="ntpoly" href="https://github.com/william-dawson/"|' ../modulesets/hpc-upstream.modules
27 sed -i 's|module="ntpoly-v3.0.0.tar.gz"|module="ntpoly"|' ../modulesets/hpc-upstream.modules
28
29 ../Installer.py autogen -y
30
31 ../Installer.py -f ../../tools/jenkins/gfortran-simgrid.rc -y build
32
33 export OMP_NUM_THREADS=1
34 #workaround issue with profiling optimization (for fugaku) which prevent f_free_ptr to use the simgrid version. Fix pending.
35 export FUTILE_PROFILING_DEPTH=-1
36
37 #cubic version
38 cd ../bigdft/tests/DFT/cubic/C
39 smpirun -hostfile $WORKSPACE/simgrid-dev/examples/smpi/hostfile -platform $WORKSPACE/simgrid-dev/examples/platforms/small_platform.xml -np 8 $WORKSPACE/build/install/bin/bigdft -l no
40
41 #Psolver checking with smpi_shared_malloc
42 cd $WORKSPACE/build/psolver/tests
43 make FC=smpif90 PS_Check
44 smpirun -hostfile $WORKSPACE/simgrid-dev/examples/smpi/hostfile -platform $WORKSPACE/simgrid-dev/examples/platforms/small_platform.xml -np 4 ./PS_Check -n [57,48,63] -g F
45
46 #linear scaling version (heavy, might swap)
47 cd $WORKSPACE/bigdft/tests/DFT/linear/surface
48 smpirun -hostfile $WORKSPACE/simgrid-dev/examples/smpi/hostfile -platform $WORKSPACE/simgrid-dev/examples/platforms/small_platform.xml -np 4 $WORKSPACE/build/install/bin/bigdft -n graphene -l no
49
50 cd $WORKSPACE/build
51 ../Installer.py -f ../../tools/jenkins/gfortran-simgrid.rc -y clean