3 ms·
Go has different memory layout and calling conventions in part because of its green threads implementation. It has to switch stacks to call C code because the G
by Rusky 10y ago
Go has different memory layout and calling conventions in part because of its green threads implementation. It has to switch stacks to call C code because the Go stacks are small and relocatable, to make growing more efficient, which is only possible because of the GC.