Source file src/runtime/stubs_s390x.go

     1  // Copyright 2019 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  package runtime
     6  
     7  import "unsafe"
     8  
     9  // Called from assembly only; declared for go vet.
    10  //
    11  // load_g is also called from runtime/cgo.
    12  //
    13  // load_g should be an internal detail,
    14  // but widely used packages access it using linkname.
    15  // Notable members of the hall of shame include:
    16  //   - github.com/ebitengine/purego
    17  //
    18  //go:linkname load_g
    19  func load_g()
    20  func save_g()
    21  
    22  //go:noescape
    23  func asmcgocall_no_g(fn, arg unsafe.Pointer)
    24  
    25  // Used by reflectcall and the reflect package.
    26  //
    27  // Spills/loads arguments in registers to/from an internal/abi.RegArgs
    28  // respectively. Does not follow the Go ABI.
    29  //
    30  //go:linknamestd spillArgs
    31  func spillArgs()
    32  
    33  //go:linknamestd unspillArgs
    34  func unspillArgs()
    35  
    36  // getfp returns the frame pointer register of its caller or 0 if not implemented.
    37  // TODO: Make this a compiler intrinsic
    38  //
    39  //go:nosplit
    40  func getfp() uintptr { return 0 }
    41  

View as plain text