aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/internal/task/gc_stack_chain.go
blob: 07588d4093279dedbe4e4cd18786636c15cd8d78 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
//go:build gc.conservative && tinygo.wasm
// +build gc.conservative,tinygo.wasm

package task

import "unsafe"

//go:linkname swapStackChain runtime.swapStackChain
func swapStackChain(dst *unsafe.Pointer)

type gcData struct {
	stackChain unsafe.Pointer
}

func (gcd *gcData) swap() {
	swapStackChain(&gcd.stackChain)
}