Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: FFTW 3.3.5: How Many Threads to Use? Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: Chris@42:
Chris@42:

Chris@42: Next: , Previous: , Up: Multi-threaded FFTW   [Contents][Index]

Chris@42:
Chris@42:
Chris@42: Chris@42:

5.3 How Many Threads to Use?

Chris@42: Chris@42: Chris@42:

There is a fair amount of overhead involved in synchronizing threads, Chris@42: so the optimal number of threads to use depends upon the size of the Chris@42: transform as well as on the number of processors you have. Chris@42:

Chris@42:

As a general rule, you don’t want to use more threads than you have Chris@42: processors. (Using more threads will work, but there will be extra Chris@42: overhead with no benefit.) In fact, if the problem size is too small, Chris@42: you may want to use fewer threads than you have processors. Chris@42:

Chris@42:

You will have to experiment with your system to see what level of Chris@42: parallelization is best for your problem size. Typically, the problem Chris@42: will have to involve at least a few thousand data points before threads Chris@42: become beneficial. If you plan with FFTW_PATIENT, it will Chris@42: automatically disable threads for sizes that don’t benefit from Chris@42: parallelization. Chris@42: Chris@42:

Chris@42: Chris@42: Chris@42: Chris@42: Chris@42: