You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

syscall_aix_gccgo.go 726B

1234567891011121314151617181920212223242526
  1. // Copyright 2020 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. // Recreate a getsystemcfg syscall handler instead of
  5. // using the one provided by x/sys/unix to avoid having
  6. // the dependency between them. (See golang.org/issue/32102)
  7. // Moreover, this file will be used during the building of
  8. // gccgo's libgo and thus must not used a CGo method.
  9. //go:build aix && gccgo
  10. package cpu
  11. import (
  12. "syscall"
  13. )
  14. //extern getsystemcfg
  15. func gccgoGetsystemcfg(label uint32) (r uint64)
  16. func callgetsystemcfg(label int) (r1 uintptr, e1 syscall.Errno) {
  17. r1 = uintptr(gccgoGetsystemcfg(uint32(label)))
  18. e1 = syscall.GetErrno()
  19. return
  20. }