Reading a bit about Go's goroutine scheduler. Sounds like it tries to solve many of the same problems a GPU's shader core does. # threads ("goroutines") >> # of simds ("OS threads"), fast switching, small stacks, minimal fairness, turn blocking calls into async calls.
-
-
Async/await is likewise stackless and avoids the OS library incompatibility problem. If you want M:N, I think a better solution is reviving something like Paul Turner’s switchto patch or Windows fibers. http://pdxplumbers.osuosl.org/2013/ocw//system/presentations/1653/original/LPC%20-%20User%20Threading.pdf …
-
This adds the primitive necessary for M:N into the kernel (a user-level “switch to thread X” syscall), avoiding the OS incompatibility problem. Windows already has this via fibers (which is why I think it’s a better solution than Go’s).
- 4 more replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.