3 ms·
"Don't read the design doc, it's too complicated. Instead read this cutpaste!" The single "lock free" idlep looks like it's just moved the futex contention els
by hosay123 13y ago
"Don't read the design doc, it's too complicated. Instead read this cutpaste!"
The single "lock free" idlep looks like it's just moved the futex contention elsewhere. This will almost certainly bounce like crazy on a many-cored system. Would be interested to see benchmarks of the new design before considering it somehow better.
- pron 13y ago> The single "lock free" idlep looks like it's just moved the futex contention elsewhere. Possibly. The Go 1.1 scheduler is inspired by Java's fork/join scheduler, which suffered from the same problem in Java 7. In Java 8 it's been improved to no longer have a single wait-list, and external submissions of tasks (i.e. tasks that are not submitted by tasks running in the thread pool, but elsewhere) are multiplexed randomly (IIRC) among the individual thread queues.
- Arnor 13y agoI concur. While the article made sense and the decisions seemed logical, I'm shy of the level of knowledge necessary to come up with healthy criticism. A nice quantitative benchmark would clear things up an awful lot.