TIL: Go not only passes all arguments via the stack on x86-64, it passes *return values* via the stack too. 
-
-
Plausible. I mean there's discussion about the effect more-registery conventions would have on gc/growth, schedule/switch, panic/unwind etc. in the code (and issue trackers, eg. https://github.com/golang/go/issues/18597 …) but I can't find a definitive comment.
-
(Also plausible: was initially built on the plan 9 C compiler backend which is explicitly caller-save, see sec 4.1 of https://9p.io/sys/doc/compiler.html … .. though I think I'd need more coffee to convince myself the saving & passing code overlaps in say https://github.com/0intro/plan9/blob/master/sys/src/cmd/6c/txt.c#L165 …)
- 2 more replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.