Open OndrejMarsalek opened 10 years ago
We should remove code for irrelevant platform-specific libraries. Only ESSL should be kept.
The generic FFT option should be turned into a compile-time setting, rather than an input setting, so that exactly one FFT library is enabled. This should probably be a silent default if not other FFT libraries are enabled.
Then FFTW should be added as a third compile-time option with a suitable macro.
Doing this in a clean way would require major changes in data structures. We would need a 1D FFT package, whereas currently all the data is kept in the 3D package. For now, we add FFTW in a way that is simple but not very nice.
Some more care is probably needed with memory allocation and alignment:
http://www.fftw.org/fftw3_doc/New_002darray-Execute-Functions.html
The fftw
branch has Joe's old code. It does not work, however, (huge forces in wavefunction minimization). Joe's old code does the same, though, at least on my Mac with FFTW 3.3.4.
Hmm, so an empirical FF with PME work fine. We should investigate a bit more. For now, we should at least check for a combination of DFT and FFTW and quit.
This should be pretty straightforward. Can be based on the older version by Joe, but should be added to the 1D wrapper, rather than the 3D FFT functions.
Let's consider whether we really need to keep support for the various special platform libraries. Removing them would simplify things.