diff options
author | Sebastian Berg <sebastian@sipsolutions.net> | 2020-06-08 08:56:54 -0500 |
---|---|---|
committer | Sebastian Berg <sebastian@sipsolutions.net> | 2020-06-25 20:44:17 -0500 |
commit | ec62be21cf109dac436f9a68a84fbd674c1faebb (patch) | |
tree | 55f7851ab35d920bccc0717c399a5cdff252fb1e /numpy/lib/arraypad.py | |
parent | 267621f07a902eceffc179fa01f984f3e2d4bdcd (diff) | |
download | numpy-ec62be21cf109dac436f9a68a84fbd674c1faebb.tar.gz |
BUG: Remove non-threadsafe sigint handling from fft calculation
The fft calculation is the only point in our code where this function
is used. Allowing Ctrl+C, in FFT specifically used have more reasons,
since before pocketfft, some array-sizes could lead to very large
run-times.
Pocketfft fixed that issue, and now FFT is not really any slower,
faster, or memory hungry than any other NumPy operation so it feels
it does not need this handling. Rather, if we can find a better
solution, it should also be added to more functions.
The reason for removal is that it is not only unsafe while the
FFT is running (in theory). Multiple, threaded FFT run can easily
leave the signal handler in a bad state, causing crashes if Ctrl+C
(sigint) is given at any point after the call.
It would be possible to patch that over, by only resetting the
signal handler if we actually changed it (or even more complex
tricks), or possibly only using this technique when on the main
thread.
But, all of these solutions seem to complicate things, when the
main reason for why allowing sigint seems useful is gone with
pocketfft.
Diffstat (limited to 'numpy/lib/arraypad.py')
0 files changed, 0 insertions, 0 deletions