Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

cgo doesn't copy the stack to a "bigger stack" when calling a C function. It just uses another stack, dedicated to cgo, and disallows passing pointers into the stack:

https://github.com/golang/go/issues/11089

So I think the slowness is caused by something else.

Thanks for sharing the benchmark.



ah, that makes more sense. thanks.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: