4 ms·
A nuance I wish I had expressed better in this article is that it's targeting functions that would otherwise be written in assembly: they'd have to be quick (no
by FiloSottile 7y ago
A nuance I wish I had expressed better in this article is that it's targeting functions that would otherwise be written in assembly: they'd have to be quick (not to undermine the scheduler) and non-recursive (not to blow the stack). For just calling larger Rust functions one can use cgo.
- scottlamb 7y ago+1. There's a reason cgo sets up another stack; calling into Rust instead of C doesn't change that. What are the consequences if you blow the stack in Go [edit: to clarify, I mean if your code in another language that doesn't understand Go's stack copying calling convention blows Go's stack]? Is there a guard page (so SIGSEGV) or does it just corrupt memory?