mirror of
https://github.com/paboyle/Grid.git
synced 2024-11-09 23:45:36 +00:00
Better check and benchmark driving
This commit is contained in:
parent
697c0603ce
commit
751f2b9703
@ -5,10 +5,13 @@ include $(top_srcdir)/doxygen.inc
|
|||||||
|
|
||||||
bin_SCRIPTS=grid-config
|
bin_SCRIPTS=grid-config
|
||||||
|
|
||||||
tests: all
|
|
||||||
$(MAKE) -C tests tests
|
|
||||||
|
|
||||||
.PHONY: tests doxygen-run doxygen-doc $(DX_PS_GOAL) $(DX_PDF_GOAL)
|
.PHONY: bench check tests doxygen-run doxygen-doc $(DX_PS_GOAL) $(DX_PDF_GOAL)
|
||||||
|
|
||||||
|
tests-local: all
|
||||||
|
bench-local: all
|
||||||
|
check-local: tests
|
||||||
|
|
||||||
AM_CXXFLAGS += -I$(top_builddir)/include
|
AM_CXXFLAGS += -I$(top_builddir)/include
|
||||||
|
|
||||||
ACLOCAL_AMFLAGS = -I m4
|
ACLOCAL_AMFLAGS = -I m4
|
||||||
|
@ -35,8 +35,9 @@ using namespace Grid::QCD;
|
|||||||
int main (int argc, char ** argv)
|
int main (int argc, char ** argv)
|
||||||
{
|
{
|
||||||
Grid_init(&argc,&argv);
|
Grid_init(&argc,&argv);
|
||||||
|
#define LMAX (32)
|
||||||
|
|
||||||
int Nloop=1000;
|
int Nloop=200;
|
||||||
|
|
||||||
std::vector<int> simd_layout = GridDefaultSimd(Nd,vComplex::Nsimd());
|
std::vector<int> simd_layout = GridDefaultSimd(Nd,vComplex::Nsimd());
|
||||||
std::vector<int> mpi_layout = GridDefaultMpi();
|
std::vector<int> mpi_layout = GridDefaultMpi();
|
||||||
@ -50,7 +51,7 @@ int main (int argc, char ** argv)
|
|||||||
std::cout<<GridLogMessage << " L "<<"\t\t"<<"bytes"<<"\t\t\t"<<"GB/s\t\t GFlop/s"<<std::endl;
|
std::cout<<GridLogMessage << " L "<<"\t\t"<<"bytes"<<"\t\t\t"<<"GB/s\t\t GFlop/s"<<std::endl;
|
||||||
std::cout<<GridLogMessage << "----------------------------------------------------------"<<std::endl;
|
std::cout<<GridLogMessage << "----------------------------------------------------------"<<std::endl;
|
||||||
|
|
||||||
for(int lat=2;lat<=32;lat+=2){
|
for(int lat=2;lat<=LMAX;lat+=2){
|
||||||
|
|
||||||
std::vector<int> latt_size ({lat*mpi_layout[0],lat*mpi_layout[1],lat*mpi_layout[2],lat*mpi_layout[3]});
|
std::vector<int> latt_size ({lat*mpi_layout[0],lat*mpi_layout[1],lat*mpi_layout[2],lat*mpi_layout[3]});
|
||||||
int vol = latt_size[0]*latt_size[1]*latt_size[2]*latt_size[3];
|
int vol = latt_size[0]*latt_size[1]*latt_size[2]*latt_size[3];
|
||||||
@ -82,7 +83,7 @@ int main (int argc, char ** argv)
|
|||||||
std::cout<<GridLogMessage << " L "<<"\t\t"<<"bytes"<<"\t\t\t"<<"GB/s\t\t GFlop/s"<<std::endl;
|
std::cout<<GridLogMessage << " L "<<"\t\t"<<"bytes"<<"\t\t\t"<<"GB/s\t\t GFlop/s"<<std::endl;
|
||||||
std::cout<<GridLogMessage << "----------------------------------------------------------"<<std::endl;
|
std::cout<<GridLogMessage << "----------------------------------------------------------"<<std::endl;
|
||||||
|
|
||||||
for(int lat=2;lat<=32;lat+=2){
|
for(int lat=2;lat<=LMAX;lat+=2){
|
||||||
|
|
||||||
std::vector<int> latt_size ({lat*mpi_layout[0],lat*mpi_layout[1],lat*mpi_layout[2],lat*mpi_layout[3]});
|
std::vector<int> latt_size ({lat*mpi_layout[0],lat*mpi_layout[1],lat*mpi_layout[2],lat*mpi_layout[3]});
|
||||||
int vol = latt_size[0]*latt_size[1]*latt_size[2]*latt_size[3];
|
int vol = latt_size[0]*latt_size[1]*latt_size[2]*latt_size[3];
|
||||||
@ -113,7 +114,7 @@ int main (int argc, char ** argv)
|
|||||||
std::cout<<GridLogMessage << " L "<<"\t\t"<<"bytes"<<"\t\t\t"<<"GB/s\t\t GFlop/s"<<std::endl;
|
std::cout<<GridLogMessage << " L "<<"\t\t"<<"bytes"<<"\t\t\t"<<"GB/s\t\t GFlop/s"<<std::endl;
|
||||||
std::cout<<GridLogMessage << "----------------------------------------------------------"<<std::endl;
|
std::cout<<GridLogMessage << "----------------------------------------------------------"<<std::endl;
|
||||||
|
|
||||||
for(int lat=2;lat<=32;lat+=2){
|
for(int lat=2;lat<=LMAX;lat+=2){
|
||||||
|
|
||||||
std::vector<int> latt_size ({lat*mpi_layout[0],lat*mpi_layout[1],lat*mpi_layout[2],lat*mpi_layout[3]});
|
std::vector<int> latt_size ({lat*mpi_layout[0],lat*mpi_layout[1],lat*mpi_layout[2],lat*mpi_layout[3]});
|
||||||
int vol = latt_size[0]*latt_size[1]*latt_size[2]*latt_size[3];
|
int vol = latt_size[0]*latt_size[1]*latt_size[2]*latt_size[3];
|
||||||
@ -144,7 +145,7 @@ int main (int argc, char ** argv)
|
|||||||
std::cout<<GridLogMessage << " L "<<"\t\t"<<"bytes"<<"\t\t\t"<<"GB/s\t\t GFlop/s"<<std::endl;
|
std::cout<<GridLogMessage << " L "<<"\t\t"<<"bytes"<<"\t\t\t"<<"GB/s\t\t GFlop/s"<<std::endl;
|
||||||
std::cout<<GridLogMessage << "----------------------------------------------------------"<<std::endl;
|
std::cout<<GridLogMessage << "----------------------------------------------------------"<<std::endl;
|
||||||
|
|
||||||
for(int lat=2;lat<=32;lat+=2){
|
for(int lat=2;lat<=LMAX;lat+=2){
|
||||||
|
|
||||||
std::vector<int> latt_size ({lat*mpi_layout[0],lat*mpi_layout[1],lat*mpi_layout[2],lat*mpi_layout[3]});
|
std::vector<int> latt_size ({lat*mpi_layout[0],lat*mpi_layout[1],lat*mpi_layout[2],lat*mpi_layout[3]});
|
||||||
int vol = latt_size[0]*latt_size[1]*latt_size[2]*latt_size[3];
|
int vol = latt_size[0]*latt_size[1]*latt_size[2]*latt_size[3];
|
||||||
|
@ -1,11 +1,7 @@
|
|||||||
include Make.inc
|
include Make.inc
|
||||||
|
|
||||||
simple: simple_su3_test.o simple_su3_expr.o simple_simd_test.o
|
bench-local: all
|
||||||
|
./Benchmark_su3
|
||||||
EXTRA_LIBRARIES = libsimple_su3_test.a libsimple_su3_expr.a libsimple_simd_test.a
|
./Benchmark_memory_bandwidth
|
||||||
|
./Benchmark_wilson
|
||||||
libsimple_su3_test_a_SOURCES = simple_su3_test.cc
|
./Benchmark_dwf --dslash-unroll
|
||||||
|
|
||||||
libsimple_su3_expr_a_SOURCES = simple_su3_expr.cc
|
|
||||||
|
|
||||||
libsimple_simd_test_a_SOURCES = simple_simd_test.cc
|
|
@ -4,6 +4,7 @@ AC_CANONICAL_BUILD
|
|||||||
AC_CANONICAL_HOST
|
AC_CANONICAL_HOST
|
||||||
AC_CANONICAL_TARGET
|
AC_CANONICAL_TARGET
|
||||||
AM_INIT_AUTOMAKE(subdir-objects)
|
AM_INIT_AUTOMAKE(subdir-objects)
|
||||||
|
AM_EXTRA_RECURSIVE_TARGETS([tests bench])
|
||||||
AC_CONFIG_MACRO_DIR([m4])
|
AC_CONFIG_MACRO_DIR([m4])
|
||||||
AC_CONFIG_SRCDIR([lib/Grid.h])
|
AC_CONFIG_SRCDIR([lib/Grid.h])
|
||||||
AC_CONFIG_HEADERS([lib/Config.h],[sed -i 's|PACKAGE_|GRID_|' lib/Config.h])
|
AC_CONFIG_HEADERS([lib/Config.h],[sed -i 's|PACKAGE_|GRID_|' lib/Config.h])
|
||||||
|
@ -23,8 +23,7 @@ for subdir in $dirs; do
|
|||||||
TESTS=`ls T*.cc`
|
TESTS=`ls T*.cc`
|
||||||
TESTLIST=`echo ${TESTS} | sed s/.cc//g `
|
TESTLIST=`echo ${TESTS} | sed s/.cc//g `
|
||||||
PREF=`[ $subdir = '.' ] && echo noinst || echo EXTRA`
|
PREF=`[ $subdir = '.' ] && echo noinst || echo EXTRA`
|
||||||
SUB=`[ $subdir = '.' ] && echo subtests`
|
echo "tests-local: ${TESTLIST} " > Make.inc
|
||||||
echo "tests: ${TESTLIST} ${SUB}" > Make.inc
|
|
||||||
echo ${PREF}_PROGRAMS = ${TESTLIST} >> Make.inc
|
echo ${PREF}_PROGRAMS = ${TESTLIST} >> Make.inc
|
||||||
echo >> Make.inc
|
echo >> Make.inc
|
||||||
HADLINK=`[ $subdir = './hadrons' ] && echo '-lHadrons '`
|
HADLINK=`[ $subdir = './hadrons' ] && echo '-lHadrons '`
|
||||||
|
@ -1,12 +1,17 @@
|
|||||||
SUBDIRS = core forces hmc solver debug smearing IO
|
SUBDIRS = . core forces hmc solver debug smearing
|
||||||
|
|
||||||
if BUILD_CHROMA_REGRESSION
|
if BUILD_CHROMA_REGRESSION
|
||||||
SUBDIRS+= qdpxx
|
SUBDIRS+= qdpxx
|
||||||
endif
|
endif
|
||||||
|
|
||||||
.PHONY: subtests
|
|
||||||
|
|
||||||
include Make.inc
|
include Make.inc
|
||||||
|
|
||||||
subtests:
|
check-local: all
|
||||||
for d in $(SUBDIRS); do $(MAKE) -C $${d} tests; done
|
./Test_simd
|
||||||
|
./Test_cshift
|
||||||
|
./Test_stencil
|
||||||
|
./Test_cayley_even_odd_vec
|
||||||
|
./Test_dwf_mixedcg_prec
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -1 +1,14 @@
|
|||||||
|
.PHONY: check
|
||||||
|
|
||||||
include Make.inc
|
include Make.inc
|
||||||
|
|
||||||
|
check: all
|
||||||
|
./Test_rect_force
|
||||||
|
./Test_gp_rect_force
|
||||||
|
./Test_laplacian_force
|
||||||
|
./Test_wilson_force
|
||||||
|
./Test_gpwilson_force
|
||||||
|
./Test_dwf_force
|
||||||
|
./Test_dwf_gpforce
|
||||||
|
./Test_mobius_force
|
||||||
|
./Test_zmobius_force
|
||||||
|
Loading…
Reference in New Issue
Block a user