xref: /aosp_15_r20/external/libcap/contrib/bug216610/go/fibber/fibs_linux_amd64.s (revision 2810ac1b38eead2603277920c78344c84ddf3aff)
1// To transition from a Go call to a C function call, we are skating
2// on really thin ice... Ceveat Emptor!
3//
4// Ref:
5//   https://gitlab.com/x86-psABIs/x86-64-ABI/-/wikis/home
6//
7// This is not strictly needed, but it makes gdb debugging less
8// confusing because spacer ends up being an alias for the TEXT
9// section start.
10TEXT ·spacer(SB),$0
11	RET
12
13#define RINDEX(n) (8*n)
14
15// Header to this function wrapper is the last time we can voluntarily
16// yield to some other goroutine.
17TEXT ·syso(SB),$0-16
18	MOVQ cFn+RINDEX(0)(FP), SI
19	MOVQ state+RINDEX(1)(FP), DI
20	CALL *SI
21	RET
22