Processor counts in tests
On my laptop, tests run with nproc
instances of a one processor test, not one test using nproc
processors. This is not the expected behaviour, or the behaviour seen in the pipelines. Does anyone else observe this?
Comments (13)
-
-
I've not tested this, but it will depend on which system makefile you're using (some define testexec etc. whilst others don't).
(Looking into these makefiles I think we'll need to overhaul some of this to improve the ability to maintain+develop this.)
-
reporter Thanks both. @ZedThree does the test output report:
Running on 2 processors
-
Looks like it:
make[2]: Entering directory '/home/peter/Codes/gyrokinetics/gs2/tests/unit_tests/asym_geo_genElong' Job -1 Running on 2 processors
The very first test looks like this though:
Reading CHEASE input file: ogyropsi.dat 41 <---npsi_chease 200 <---nchi_chease Job -1 Running on 2 processors Job 1 is called wstar_units_false and is running on 1 processor Job 0 is called wstar_units and is running on 1 processor Finished ceqin... imported CHEASE equilibrium
-
reporter @daviddickinson I've defined
TESTEXEC='mpirun -np 6'
, but it runs six copies of a one proc job. -
What if you don't define
TESTEXEC
but do defineNPROCS
orNPROCTEST
(or whatever it is called)? -
reporter Thanks @ZedThree, that looks right. What is your
GK_SYSTEM
? -
Just for sanity, what happens if you actually run
mpirun -np 6 ./test_name test_input.in
? -
This is my Makefile.local:
# -*- mode: makefile-gmake -*- MAKEFLAGS = -I Makefiles GK_SYSTEM = gnu_ubuntu DEBUG = on USE_F200X_INTRINSICS = on FFT_INC = -I/usr/include NETCDF_INC = -I/usr/local/include NETCDF_LIB = -L/usr/local/lib64 -lnetcdff -lnetcdf F90FLAGS += -Wall -Wextra -std=gnu -ffree-form ONE_STEP_PP = on
-
reporter @daviddickinson :
$ mpirun -np 6 ./test_gs2_diagnostics test_gs2_diagnostics.in Running on 1 processor Running on 1 processor Running on 1 processor Running on 1 processor Running on 1 processor Running on 1 processor
-
You've compiled with a serial compiler or use_mpi undefined
-
reporter Thanks @daviddickinson , it's that. Why, yes, I have been messy around with
update-alternatives --config mpi
... -
reporter - changed status to closed
- Log in to comment
When I run
make tests
, all the tests run withmpirun -np 2
, e.g. :passed: gs2_init (mpirun -np 2 ./test_gs2_init test_gs2_init.in )