-
Notifications
You must be signed in to change notification settings - Fork 32
Description
I'm using a single OSCInPort to receive OSC messages and I noticed that it's responsible for a lot of thread sleeping / waking.
With the default interval of 0.01secs I'm seeing around 170 wake-ups per second in Activity Monitor. Extending the interval does of course reduce the wake-ups but it still seems like a lot.
Having a lot of wake-ups causes a warning in the Console along the lines of 'process Xxxxx[yyyy] caught causing excessive wakeups.' 'Maximum permitted wakeups rate (per sec): 150'.
As far as I can tell this message is just a warning (doesn't seem to have any effect) and it usually triggers when the wakeups count actually goes quite a lot higher than 150, but still it got me thinking maybe this was something worth optimising.
What do you think, is this something that could be done a different way while still being responsive to incoming messages?
For reference, there's some good info on this page about monitoring wakeups etc: https://developer.apple.com/library/mac/documentation/Performance/Conceptual/power_efficiency_guidelines_osx/Timers.html