mersenneforum.org  

Go Back   mersenneforum.org > Great Internet Mersenne Prime Search > Software

Reply
 
Thread Tools
Old 2011-02-25, 19:58   #1
ixfd64
Bemusing Prompter
 
ixfd64's Avatar
 
"Danny"
Dec 2002
California

45338 Posts
Default FFTW vs. gwnum?

According to Wikipedia, FFTW is the fastest free FFT library. However, it also goes without saying that gwnum (George Woltman's FFT library) is world-class code. Does anyone know how gwnum compares to FFTW? The FFTW benchmarks webpage does rank it among other programs, but there is no mention of Prime95; the closest thing is Ernst's implementation.

Nevertheless, I'd suspect gwnum to be faster because it uses assembly for its core operations, while FFTW uses C subroutines. If FFTW was faster, then George would have used it already.

After all, I don't think the FFTW folks are wrong when they claim it's the fastest free FFT library because Prime95 isn't technically free software (due to the EFF prize distribution terms). :P

Last fiddled with by ixfd64 on 2011-02-25 at 19:59
ixfd64 is offline   Reply With Quote
Old 2011-02-25, 20:03   #2
henryzz
Just call me Henry
 
henryzz's Avatar
 
"David"
Sep 2007
Cambridge (GMT/BST)

2·33·109 Posts
Default

AFAIK as long as you aren't searching for mersenne primes using GWNUM there are no restrictions.
henryzz is offline   Reply With Quote
Old 2011-09-17, 08:40   #3
Dubslow
Basketry That Evening!
 
Dubslow's Avatar
 
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88

722110 Posts
Default

So P95 doesn't use the FFTW? I was wondering about that.
Also, how dooes the CUFFT library compare to FFTW or P95?
Dubslow is offline   Reply With Quote
Old 2011-09-17, 12:34   #4
jasonp
Tribal Bullet
 
jasonp's Avatar
 
Oct 2004

3·1,181 Posts
Default

All of the FFT code in Prime95 is custom-written by George. The first version of FFTW was released around 1999. People in the GPU subforum have much more experience with CuFFTW, you should ask them for more specifics.
jasonp is offline   Reply With Quote
Old 2011-09-18, 15:49   #5
cheesehead
 
cheesehead's Avatar
 
"Richard B. Woods"
Aug 2002
Wisconsin USA

1E0C16 Posts
Default

Quote:
Originally Posted by Dubslow View Post
So P95 doesn't use the FFTW? I was wondering about that.
Note that FFTW is written in C and is portable.

Much of Prime95's FFT code is written in assembly language for Intel or Intel-compatible CPUs. That allows it to be better optimized for speed on Intel-compatible architecture than FFTW can be, but it's not portable to other architectures.
cheesehead is offline   Reply With Quote
Old 2011-09-18, 20:55   #6
Christenson
 
Christenson's Avatar
 
Dec 2010
Monticello

5·359 Posts
Default

Hasn't P95 also got some AMD-specific kernels, too?
Christenson is offline   Reply With Quote
Old 2011-09-18, 22:24   #7
jasonp
Tribal Bullet
 
jasonp's Avatar
 
Oct 2004

3·1,181 Posts
Default

Yes, there are SSE2 kernels designed for Opterons in 64-bit mode (and probably 32-bit mode as well, the lack of such kernels was a hot-button issue a few years ago).

Likewise, FFTW has extensive inline assembly depending on the compiler (usually assumed to be gcc)
jasonp is offline   Reply With Quote
Old 2011-09-20, 16:05   #8
ewmayer
2ω=0
 
ewmayer's Avatar
 
Sep 2002
República de California

2×32×647 Posts
Default

Quote:
Originally Posted by ixfd64 View Post
According to Wikipedia, FFTW is the fastest free FFT library. However, it also goes without saying that gwnum (George Woltman's FFT library) is world-class code. Does anyone know how gwnum compares to FFTW? The FFTW benchmarks webpage does rank it among other programs, but there is no mention of Prime95; the closest thing is Ernst's implementation.
If you're talking about the version of my code listed in the FFTW benchmarks, that is ~15 years old, my very early-stage Fortran-90 FFT implementation. My current FFT library is generic C with lots of SSE2 inline assembler for SSE2-supporting hardware. Not as highly-tuned as George's, probably runs at best 2/3 as fast. Haven't had time or interest to do detailed comparisons vs FFTW, but anyone who likes can download the code (I've done work on it since that snapshot, but that should suffice to give a pretty idea of relative performance), build locally (using Visual Studio or MinGW32 under Win32, GCC under Linux/MacOS, or MinGW64 under Win64) land do comparative timings.

Last fiddled with by ewmayer on 2011-09-20 at 16:10
ewmayer is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
Question about FFTW vs. gwnum? hangxanh Software 2 2014-10-24 15:48
llrp, a portable version of LLR using FFTW Jean Penné Software 16 2012-04-08 13:43
LLR V3.8.2 using gwnum 26.2 is available! Jean Penné Software 25 2010-11-01 15:18
GWNUM? Unregistered Information & Answers 3 2010-09-12 19:52
GWNUM as DLL? Cyclamen Persicum Software 1 2007-01-02 20:53

All times are UTC. The time now is 19:38.


Sun Aug 1 19:38:38 UTC 2021 up 9 days, 14:07, 0 users, load averages: 0.94, 1.36, 1.61

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.