Nicer solution for fftw3_threads
This commit is contained in:
@ -56,7 +56,7 @@ CLEANFILES = *Dict.cpp *Dict.h *~ core
|
||||
lib_LTLIBRARIES = libTFitPofB.la
|
||||
|
||||
libTFitPofB_la_SOURCES = $(h_sources) $(cpp_sources) $(dict_h_sources) $(dict_cpp_sources)
|
||||
libTFitPofB_la_LIBADD = $(LEM_LIBS) $(PMUSR_LIBS) $(FFTW3_THREADS_LIBS) $(ROOT_LIBS)
|
||||
libTFitPofB_la_LIBADD = $(LEM_LIBS) $(PMUSR_LIBS) $(FFTW3_LIBS) $(ROOT_LIBS)
|
||||
libTFitPofB_la_LDFLAGS = -version-info $(PLUGIN_LIBRARY_VERSION) -release $(PLUGIN_RELEASE) $(AM_LDFLAGS)
|
||||
|
||||
## For the moment do not build pkgconfig files for musrfit plug-ins...
|
||||
|
@ -128,9 +128,11 @@ TBulkTriVortexLondonFieldCalc::TBulkTriVortexLondonFieldCalc(const string& wisdo
|
||||
fParam.resize(3);
|
||||
fGridExists = false;
|
||||
|
||||
#ifdef HAVE_LIBFFTW3_THREADS
|
||||
int init_threads(fftw_init_threads());
|
||||
if (init_threads)
|
||||
fftw_plan_with_nthreads(2);
|
||||
#endif /* HAVE_LIBFFTW3_THREADS */
|
||||
|
||||
fFFTin = new fftw_complex[(fSteps/2 + 1) * fSteps];
|
||||
fFFTout = new double[fSteps*fSteps];
|
||||
@ -295,9 +297,11 @@ TBulkTriVortexMLFieldCalc::TBulkTriVortexMLFieldCalc(const string& wisdom, const
|
||||
fParam.resize(3);
|
||||
fGridExists = false;
|
||||
|
||||
#ifdef HAVE_LIBFFTW3_THREADS
|
||||
int init_threads(fftw_init_threads());
|
||||
if (init_threads)
|
||||
fftw_plan_with_nthreads(2);
|
||||
#endif /* HAVE_LIBFFTW3_THREADS */
|
||||
|
||||
fFFTin = new fftw_complex[(fSteps/2 + 1) * fSteps];
|
||||
fFFTout = new double[fSteps*fSteps];
|
||||
@ -465,9 +469,11 @@ TBulkTriVortexAGLFieldCalc::TBulkTriVortexAGLFieldCalc(const string& wisdom, con
|
||||
fParam.resize(3);
|
||||
fGridExists = false;
|
||||
|
||||
#ifdef HAVE_LIBFFTW3_THREADS
|
||||
int init_threads(fftw_init_threads());
|
||||
if (init_threads)
|
||||
fftw_plan_with_nthreads(2);
|
||||
#endif /* HAVE_LIBFFTW3_THREADS */
|
||||
|
||||
fFFTin = new fftw_complex[(fSteps/2 + 1) * fSteps];
|
||||
fFFTout = new double[fSteps*fSteps];
|
||||
@ -655,9 +661,11 @@ TBulkTriVortexNGLFieldCalc::TBulkTriVortexNGLFieldCalc(const string& wisdom, con
|
||||
fParam.resize(3);
|
||||
fGridExists = false;
|
||||
|
||||
#ifdef HAVE_LIBFFTW3_THREADS
|
||||
int init_threads(fftw_init_threads());
|
||||
if (init_threads)
|
||||
fftw_plan_with_nthreads(2);
|
||||
#endif /* HAVE_LIBFFTW3_THREADS */
|
||||
|
||||
const unsigned int stepsSq(fSteps*fSteps);
|
||||
|
||||
|
@ -65,11 +65,13 @@
|
||||
|
||||
TPofTCalc::TPofTCalc (const TPofBCalc *PofB, const string &wisdom, const vector<double> &par) : fWisdom(wisdom) {
|
||||
|
||||
#ifdef HAVE_LIBFFTW3_THREADS
|
||||
int init_threads(fftw_init_threads());
|
||||
if (!init_threads)
|
||||
cout << "TPofTCalc::TPofTCalc: Couldn't initialize multiple FFTW-threads ..." << endl;
|
||||
else
|
||||
fftw_plan_with_nthreads(2);
|
||||
#endif /* HAVE_LIBFFTW3_THREADS */
|
||||
|
||||
fNFFT = static_cast<int>(1.0/(gBar*par[1]*par[2]));
|
||||
if (fNFFT % 2) {
|
||||
|
2
src/external/libLFRelaxation/Makefile.am
vendored
2
src/external/libLFRelaxation/Makefile.am
vendored
@ -33,7 +33,7 @@ CLEANFILES = *Dict.cpp *Dict.h *~ core
|
||||
lib_LTLIBRARIES = libLFRelaxation.la
|
||||
|
||||
libLFRelaxation_la_SOURCES = $(h_sources) $(cpp_sources) $(dict_h_sources) $(dict_cpp_sources)
|
||||
libLFRelaxation_la_LIBADD = $(PMUSR_LIBS) $(FFTW3_THREADS_LIBS) $(GSL_LIBS) $(ROOT_LIBS) $(CUBA_LIBS)
|
||||
libLFRelaxation_la_LIBADD = $(PMUSR_LIBS) $(FFTW3_LIBS) $(GSL_LIBS) $(ROOT_LIBS) $(CUBA_LIBS)
|
||||
libLFRelaxation_la_LDFLAGS = -version-info $(PLUGIN_LIBRARY_VERSION) -release $(PLUGIN_RELEASE) $(AM_LDFLAGS)
|
||||
|
||||
## For the moment do not build pkgconfig files for musrfit plug-ins...
|
||||
|
Reference in New Issue
Block a user