sagemath / cysignals

cysignals: interrupt and signal handling for Cython. Source repository for https://pypi.org/project/cysignals/
GNU Lesser General Public License v3.0
44 stars 23 forks source link

Better support for threads #109

Closed jdemeyer closed 2 years ago

jdemeyer commented 5 years ago

This pull request aims to improve thread-safety of cysignals. There are many aspects to it and this does not claim to fix all thread-related issues. In particular, we assume that there is only 1 thread any time that sig_on() is called. In particular, we don't support Python multithreading.

jdemeyer commented 5 years ago

Testing this is harder than I thought: the obvious thing to do would be OpenMP, but apparently GCC doesn't support atomics in combination with OpenMP: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65467

jdemeyer commented 5 years ago

Now struggling with pesky $MACOSX_DEPLOYMENT_TARGET issues...

jdemeyer commented 5 years ago

I merged part of this branch already, but keeping it open since there are more thread issues to be fixed.