3 ms·
> the speed of Qt signals is not issue - it's the code responding to the signal that can be a problem. Even if the callback were infinitely fast, if it's calle
by usefulcat 4y ago
> the speed of Qt signals is not issue - it's the code responding to the signal that can be a problem.
Even if the callback were infinitely fast, if it's called 10e6 times per second, the work already can't take longer than 100 ns on average (10e6 * 100ns = 1e9ns = 1 second). So a more useful way to frame this would be in terms of the ratio of the callback overhead to the work done by the callback (both measured in time), but there's no mention of the latter.
In this particular case, this is a pretty obvious case of 'this is the wrong tool for the job', at least with the stated requirements. Also, at the point where you need to do something 10e6 times per second it's usually appropriate to think about how you might distribute that work across multiple cores.