first work to add GPU support via DKS for Fourier.

This commit is contained in:
2015-04-07 16:44:20 +02:00
parent e4f11aca8c
commit 75578f1977
7 changed files with 545 additions and 67 deletions

View File

@ -845,6 +845,33 @@ if test "x$enable_omp" != "xno"; then
[CXXFLAGS="$SAVED_CXXFLAGS" LIBS="$SAVED_LIBS"], [])
fi
dnl -----------------------------------------------
dnl Ask user if DKS support should be enabled (DKS = Dynamic Kernel Scheduler. Used to interface GPU's, MIC, etc)
dnl -----------------------------------------------
AC_ARG_ENABLE([dks], [AS_HELP_STRING([--enable-dks],[build musrfit with DKS (GPU/MIC) support [default=no]])], [DKS_ENABLED=1], [DKS_ENABLED=0])
DKS_LIBDIR=""
DKS_INCDIR=""
DKS_LIBS=""
DKS_CFLAGS=""
if test "${DKS_ENABLED}" == "1"; then
dnl ---------------------------------------------
dnl Eventually some strict testing about the availibilty of DKS should go in here
dnl Most probably it will be most sensible to ship DKS with the musrfit source code
dnl All hard wired stuff needs to disappear
dnl ---------------------------------------------
AC_DEFINE([HAVE_DKS], [1], [Define to 1 if DKS is available])
AC_DEFINE([DKS_CUDA], [1], [Define to 1 if DKS Cuda is available])
DKS_CUDADIR="/usr/local/cuda-6.5/targets/x86_64-linux"
DKS_INCDIR="/home/l_suter_a/DKS/src"
DKS_CFLAGS="-DDKS_OPENCL -DDKS_CUDA -I${DKS_INCDIR} -I${DKS_CUDADIR}/include"
DKS_LIBDIR="/home/l_suter_a/DKS/build/src"
DKS_LIBS="-L${DKS_CUDADIR}/lib -lOpenCL -L${DKS_LIBDIR} -ldksshared"
AC_SUBST(DKS_CFLAGS)
AC_SUBST(DKS_LIBS)
fi
dnl -----------------------------------------------
dnl Ask user if the building of musredit/musrgui should be disabled
dnl -----------------------------------------------
@ -1126,6 +1153,7 @@ AM_CONDITIONAL([BUILD_CUBALIB], [test "${BUILD_CUBA}" = "1"])
AM_CONDITIONAL([BUILD_BMWLIBS], [test "${BUILD_BMW_LIBS}" = "1"])
AM_CONDITIONAL([BUILD_ASLIBS], [test "${BUILD_AS_LIBS}" = "1"])
AM_CONDITIONAL([BUILD_BNMRLIBS], [test "${BUILD_BNMR_LIBS}" = "1"])
AM_CONDITIONAL([DKS_ENABLED], [test "${DKS_ENABLED}" = "1"])
AC_CONFIG_FILES([Makefile \
src/Makefile \
@ -1133,8 +1161,8 @@ AC_CONFIG_FILES([Makefile \
src/classes/PMusr.pc \
src/classes/PUserFcnBase.pc \
src/external/Makefile \
src/external/MusrRoot/Makefile \
src/external/MusrRoot/TMusrRunHeader.pc \
src/external/MusrRoot/Makefile \
src/external/MusrRoot/TMusrRunHeader.pc \
src/external/TLemRunHeader/Makefile \
src/external/TLemRunHeader/TLemRunHeader.pc \
src/external/MuSR_software/Makefile \
@ -1162,8 +1190,8 @@ AC_CONFIG_FILES([Makefile \
src/external/libCalcMeanFieldsLEM/Makefile \
src/external/Nonlocal/Makefile \
src/external/MagProximity/Makefile \
src/external/libSpinValve/Makefile \
src/external/libSpinValve/classes/Makefile \
src/external/libSpinValve/Makefile \
src/external/libSpinValve/classes/Makefile \
src/external/libPhotoMeissner/Makefile \
src/external/libPhotoMeissner/classes/Makefile \
src/external/libBNMR/Makefile \
@ -1261,11 +1289,17 @@ else
echo " Qt not needed (Qt editors disabled)"
fi
echo ""
if test "${DKS_ENABLED}" -eq 1; then
echo " DKS enabled"
else
echo " DKS disabled"
fi
echo ""
echo ""
echo " Features:"
echo " ---------"
echo ""
echo " musrfit (including musrfit, musrview, musrt0,"
echo " musrfit (including musrfit, musrview, musrFT, musrt0,"
echo " msr2msr, msr2data, any2many, dump_header,"
echo " musrRootValidation, write_musrRoot_runHeader): yes"
echo ""