Merge release-20201109.0-102-g3deb5d0c0 (automated)
This commit is contained in:
commit
acb271686d
|
@ -0,0 +1,25 @@
|
|||
// Copyright 2020 The gVisor Authors.
|
||||
//
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
// +build go1.13
|
||||
// +build !go1.14
|
||||
|
||||
package sync
|
||||
|
||||
import (
|
||||
"runtime"
|
||||
_ "unsafe" // for go:linkname
|
||||
)
|
||||
|
||||
//go:linkname canSpin sync.runtime_canSpin
|
||||
func canSpin(i int) bool
|
||||
|
||||
//go:linkname doSpin sync.runtime_doSpin
|
||||
func doSpin()
|
||||
|
||||
func goyield() {
|
||||
// goyield is not available until Go 1.14.
|
||||
runtime.Gosched()
|
||||
}
|
|
@ -3,7 +3,7 @@
|
|||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
// +build go1.13
|
||||
// +build go1.14
|
||||
// +build !go1.17
|
||||
|
||||
// Check go:linkname function signatures when updating Go version.
|
||||
|
|
Loading…
Reference in New Issue