-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make ChipMainLoopWork_WorkSchedule.cpp
work on darwin
#30425
Conversation
Switch implementation to mutex + cond-variable for python, which should hopefully work everywhere.
I found a few more instances of this sem_init. src/controller/python/chip/internal/ChipThreadWork.cpp already has darwin specific things in it (wow ... why do we have two python work bits ?) We probably should extract some binary semaphore inside core. Followup though. I want to unblock CSG for now. |
PR #30425: Size comparison from f06d952 to 9c9da0a Full report (73 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, psoc6, qpg, telink)
|
PR #30425: Size comparison from baa1d7a to 1abd3bd Increases above 0.2%:
Increases (1 build for linux)
Decreases (5 builds for bl602, bl702, efr32, linux, mbed)
Full report (73 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, psoc6, qpg, telink)
|
It turns out that
sem_init
returns ENOSYS and semaphores do not work, which makes our code here totally broken on mac.Switched implementation to a mutex & condition variable with the hope that the standard C++ library just works (it seems to work for me at least).