On 7/19/2024 9:26 AM, Bonita Montero wrote:
[...]
outside: 19937
inside: 20030 100.471%
Result: locking from inside and outside is as efficient with
Linux and glibc, only half a percent more contextswitches
with locking from inside.
Well, wait morphing should have something to do with it. ;^)
Generally, signalling a condvar while the mutex is locked is not all
that efficient...
Am 19.07.2024 um 21:05 schrieb Scott Lurndal:
"Chris M. Thomasson" <[email protected]> writes:Show me the code that shows a difference.
On 7/19/2024 9:26 AM, Bonita Montero wrote:
[...]
outside: 19937
inside: 20030 100.471%
Result: locking from inside and outside is as efficient with
Linux and glibc, only half a percent more contextswitches
with locking from inside.
Well, wait morphing should have something to do with it. ;^)
Generally, signalling a condvar while the mutex is locked is not all
that efficient...
One cannot draw any conclusions from that toy example. ...
Generally, signalling a condvar while the mutex is locked is not all
that efficient...
| Sysop: | Keyop |
|---|---|
| Location: | Huddersfield, West Yorkshire, UK |
| Users: | 715 |
| Nodes: | 16 (0 / 16) |
| Uptime: | 168:07:51 |
| Calls: | 12,096 |
| Calls today: | 4 |
| Files: | 15,003 |
| Messages: | 6,517,819 |