Skip to content

Commit

Permalink
Merge pull request #459 from danieljprice/cca
Browse files Browse the repository at this point in the history
(build) fix issues with SYSTEM=rusty
  • Loading branch information
danieljprice committed Aug 2, 2023
2 parents 6a62fb2 + a026908 commit 14dd06e
Show file tree
Hide file tree
Showing 5 changed files with 47 additions and 12 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@ jobs:
- name: "Nuke the github workspace before doing anything"
run: rm -r ${{ github.workspace }} && mkdir ${{ github.workspace }}

- name: Update package list
run: sudo apt-get update

- name: Setup Intel repo
if: matrix.system == 'ifort'
id: intel-repo
Expand Down
2 changes: 1 addition & 1 deletion build/Makefile_defaults_ifort
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ LIBCXX = -cxxlib
KNOWN_SYSTEM=yes

# for ifort version 18+ -openmp flag is obsolete
IFORT_VERSION_MAJOR=${shell ifort -v 2>&1 | cut -d' ' -f 3 | cut -d'.' -f 1}
IFORT_VERSION_MAJOR=${shell ifort -v 2>&1 | head -1 | cut -d' ' -f 3 | cut -d'.' -f 1}
ifeq ($(shell [ $(IFORT_VERSION_MAJOR) -gt 17 ] && echo true),true)
OMPFLAGS= -qopenmp
else
Expand Down
9 changes: 4 additions & 5 deletions build/Makefile_systems
Original file line number Diff line number Diff line change
Expand Up @@ -113,11 +113,10 @@ endif
ifeq ($(SYSTEM), rusty)
# Flatiron CCA rusty cluster rome node, AMD EPYC 7742
include Makefile_defaults_ifort
FFLAGS= -Ofast -mcmodel=medium -march=znver2
OMPFLAGS=-qopenmp
NOMP=64
QSYS = slurm
QNAME='rome'
QPARTITION='cca'
QSYS=slurm
QPARTITION='gen'
WALLTIME='168:00:00'
endif

Expand All @@ -128,7 +127,7 @@ ifeq ($(SYSTEM), ipopeyearch)
NOMP=64
QSYS = slurm
QNAME='icelake'
QPARTITION='cca'
QPARTITION='gen'
WALLTIME='168:00:00'
endif

Expand Down
6 changes: 2 additions & 4 deletions docs/flatiron.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Getting started on Rusty (Flatiron cluster)
===========================================

See also general instructions for :doc:`running phantom on a remote cluster <clusters>`.
See also :doc:`general instructions for running phantom on a remote cluster <clusters>`.

We assume you already have a Flatiron username and account

Expand Down Expand Up @@ -32,9 +32,7 @@ Clone a copy of phantom into your home directory::
Set your username and email address
-----------------------------------

Ensure that your name and email address are set, as follows:

::
Ensure that your name and email address are set, as follows::

cd phantom
git config --global user.name "Joe Bloggs"
Expand Down
39 changes: 37 additions & 2 deletions scripts/buildbot.sh
Original file line number Diff line number Diff line change
Expand Up @@ -72,11 +72,12 @@ echo "url = $url";
pwd=$PWD;
phantomdir="$pwd/../";
listofcomponents='main setup analysis utils';
#listofcomponents='analysis'
#listofcomponents='setup'
#
# get list of targets, components and setups to check
#
allsetups=`grep 'ifeq ($(SETUP)' $phantomdir/build/Makefile_setups | grep -v skip | cut -d, -f 2 | cut -d')' -f 1`
#allsetups='star'
setuparr=($allsetups)
batchsize=$(( ${#setuparr[@]} / $nbatch + 1 ))
offset=$(( ($batch-1) * $batchsize ))
Expand Down Expand Up @@ -195,14 +196,15 @@ check_phantomsetup ()
#
# run phantomsetup up to 3 times to successfully create/rewrite the .setup file
#
infile="${prefix}.in"
./phantomsetup $prefix < myinput.txt > /dev/null;
./phantomsetup $prefix < myinput.txt > /dev/null;
if [ -e "$prefix.setup" ]; then
print_result "creates .setup file" $pass;
#test_setupfile_options "$prefix" "$prefix.setup" $infile;
else
print_result "no .setup file" $warn;
fi
infile="${prefix}.in"
if [ -e "$infile" ]; then
print_result "creates .in file" $pass;
#
Expand Down Expand Up @@ -247,6 +249,39 @@ check_phantomsetup ()
fi
}
#
# check that all possible values of certain
# variables in the .setup file work
#
test_setupfile_options()
{
myfail=0;
setup=$1;
setupfile=$2;
infile=$3;
range=''
if [ "X$setup"=="Xstar" ]; then
param='iprofile'
range='1 2 3 4 5 6 7'
fi
for x in $range; do
valstring="$param = $x"
echo "checking $valstring"
sed "s/$param.*=.*$/$valstring/" $setupfile > ${setupfile}.tmp
cp ${setupfile}.tmp $setupfile
rm $infile
./phantomsetup $setupfile < /dev/null > /dev/null;
./phantomsetup $setupfile < /dev/null;

if [ -e $infile ]; then
print_result "successful phantomsetup with $valstring" $pass;
else
print_result "FAIL: failed to create .in file with $valstring" $fail;
myfail=$(( myfail + 1 ));
echo $setup $valstring >> $faillogsetup;
fi
done
}
#
# unit tests for phantomanalysis utility
# (currently only exist for SETUP=star)
#
Expand Down

0 comments on commit 14dd06e

Please sign in to comment.