3 ms·
I wonder how it works when you use virtual threads. In Go, goroutines have resizable stacks which notoriously complicates FFI because C has no idea about resiza
by kgeist 2y ago
I wonder how it works when you use virtual threads. In Go, goroutines have resizable stacks which notoriously complicates FFI because C has no idea about resizable stacks (IIRC they have to temporarily switch to a separate, special C stack).
- mike_hearn 2y agoWhen it's running a virtual thread is using a physical OS level thread, and if you call into C then that virtual thread won't suspend. It pins the OS thread. So it's all transparent.