3 ms·
Yep, and golang, and python with gevent (linked in the article). The general approach is often called "green threads" or "userspace threads".
by ekimekim 8y ago
Yep, and golang, and python with gevent (linked in the article). The general approach is often called "green threads" or "userspace threads".
- sifoobar 8y agoGo runs NxM threading behind the scenes, it's far from the same thing. By choice, but it's not what I'm aiming for. And it needs to be built into the core (as opposed to gevent), otherwise it wont run as fast as it could and can't integrate deeply enough with IO to be seamless.
- seabrookmx 8y agoWhen doing network calls golang will yield in a similar fashion as described in the thread above. However this is standard library magic and and user code will indeed run in the context of a goroutine which is NxM threading.