The issue will be the global interpreter lock.
Python allows the global interpreter lock to switch after a certain number of bytecode instructions (roughly). Cython code won't release the global interpreter lock unless you specifically tell it to (or unless a Python call triggers it)
So you'd do:
```
while True:
with nogil: # Note that this doesn't work well on PyPy for
some reason
pass
# or
with nogil:
WaitForSingleObject(...)
```
I believe time.sleep should release the global interpreter lock itself though.
--
---
You received this message because you are subscribed to the Google Groups "cython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cython-users...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/cython-users/766dedeb-6202-4156-a39d-3de6803a25f7n%40googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/cython-users/68773996-9876-461d-903b-de26caea7697%40d-woods.co.uk.
The issue will be the global interpreter lock.
To view this discussion visit https://groups.google.com/d/msgid/cython-users/68773996-9876-461d-903b-de26caea7697%40d-woods.co.uk.