Black Lives Matter. Support the Equal Justice Initiative.

Source file src/syscall/zsyscall_darwin_amd64.go

Documentation: syscall

     1  // mksyscall.pl -darwin -tags darwin,amd64 syscall_bsd.go syscall_darwin.go syscall_darwin_amd64.go
     2  // Code generated by the command above; DO NOT EDIT.
     3  
     4  //go:build darwin && amd64
     5  // +build darwin,amd64
     6  
     7  package syscall
     8  
     9  import "unsafe"
    10  import "internal/abi"
    11  
    12  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    13  
    14  func getgroups(ngid int, gid *_Gid_t) (n int, err error) {
    15  	r0, _, e1 := rawSyscall(abi.FuncPCABI0(libc_getgroups_trampoline), uintptr(ngid), uintptr(unsafe.Pointer(gid)), 0)
    16  	n = int(r0)
    17  	if e1 != 0 {
    18  		err = errnoErr(e1)
    19  	}
    20  	return
    21  }
    22  
    23  func libc_getgroups_trampoline()
    24  
    25  //go:cgo_import_dynamic libc_getgroups getgroups "/usr/lib/libSystem.B.dylib"
    26  
    27  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    28  
    29  func setgroups(ngid int, gid *_Gid_t) (err error) {
    30  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_setgroups_trampoline), uintptr(ngid), uintptr(unsafe.Pointer(gid)), 0)
    31  	if e1 != 0 {
    32  		err = errnoErr(e1)
    33  	}
    34  	return
    35  }
    36  
    37  func libc_setgroups_trampoline()
    38  
    39  //go:cgo_import_dynamic libc_setgroups setgroups "/usr/lib/libSystem.B.dylib"
    40  
    41  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    42  
    43  func wait4(pid int, wstatus *_C_int, options int, rusage *Rusage) (wpid int, err error) {
    44  	r0, _, e1 := syscall6(abi.FuncPCABI0(libc_wait4_trampoline), uintptr(pid), uintptr(unsafe.Pointer(wstatus)), uintptr(options), uintptr(unsafe.Pointer(rusage)), 0, 0)
    45  	wpid = int(r0)
    46  	if e1 != 0 {
    47  		err = errnoErr(e1)
    48  	}
    49  	return
    50  }
    51  
    52  func libc_wait4_trampoline()
    53  
    54  //go:cgo_import_dynamic libc_wait4 wait4 "/usr/lib/libSystem.B.dylib"
    55  
    56  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    57  
    58  func accept(s int, rsa *RawSockaddrAny, addrlen *_Socklen) (fd int, err error) {
    59  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_accept_trampoline), uintptr(s), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)))
    60  	fd = int(r0)
    61  	if e1 != 0 {
    62  		err = errnoErr(e1)
    63  	}
    64  	return
    65  }
    66  
    67  func libc_accept_trampoline()
    68  
    69  //go:cgo_import_dynamic libc_accept accept "/usr/lib/libSystem.B.dylib"
    70  
    71  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    72  
    73  func bind(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
    74  	_, _, e1 := syscall(abi.FuncPCABI0(libc_bind_trampoline), uintptr(s), uintptr(addr), uintptr(addrlen))
    75  	if e1 != 0 {
    76  		err = errnoErr(e1)
    77  	}
    78  	return
    79  }
    80  
    81  func libc_bind_trampoline()
    82  
    83  //go:cgo_import_dynamic libc_bind bind "/usr/lib/libSystem.B.dylib"
    84  
    85  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
    86  
    87  func connect(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
    88  	_, _, e1 := syscall(abi.FuncPCABI0(libc_connect_trampoline), uintptr(s), uintptr(addr), uintptr(addrlen))
    89  	if e1 != 0 {
    90  		err = errnoErr(e1)
    91  	}
    92  	return
    93  }
    94  
    95  func libc_connect_trampoline()
    96  
    97  //go:cgo_import_dynamic libc_connect connect "/usr/lib/libSystem.B.dylib"
    98  
    99  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   100  
   101  func socket(domain int, typ int, proto int) (fd int, err error) {
   102  	r0, _, e1 := rawSyscall(abi.FuncPCABI0(libc_socket_trampoline), uintptr(domain), uintptr(typ), uintptr(proto))
   103  	fd = int(r0)
   104  	if e1 != 0 {
   105  		err = errnoErr(e1)
   106  	}
   107  	return
   108  }
   109  
   110  func libc_socket_trampoline()
   111  
   112  //go:cgo_import_dynamic libc_socket socket "/usr/lib/libSystem.B.dylib"
   113  
   114  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   115  
   116  func getsockopt(s int, level int, name int, val unsafe.Pointer, vallen *_Socklen) (err error) {
   117  	_, _, e1 := syscall6(abi.FuncPCABI0(libc_getsockopt_trampoline), uintptr(s), uintptr(level), uintptr(name), uintptr(val), uintptr(unsafe.Pointer(vallen)), 0)
   118  	if e1 != 0 {
   119  		err = errnoErr(e1)
   120  	}
   121  	return
   122  }
   123  
   124  func libc_getsockopt_trampoline()
   125  
   126  //go:cgo_import_dynamic libc_getsockopt getsockopt "/usr/lib/libSystem.B.dylib"
   127  
   128  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   129  
   130  func setsockopt(s int, level int, name int, val unsafe.Pointer, vallen uintptr) (err error) {
   131  	_, _, e1 := syscall6(abi.FuncPCABI0(libc_setsockopt_trampoline), uintptr(s), uintptr(level), uintptr(name), uintptr(val), uintptr(vallen), 0)
   132  	if e1 != 0 {
   133  		err = errnoErr(e1)
   134  	}
   135  	return
   136  }
   137  
   138  func libc_setsockopt_trampoline()
   139  
   140  //go:cgo_import_dynamic libc_setsockopt setsockopt "/usr/lib/libSystem.B.dylib"
   141  
   142  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   143  
   144  func getpeername(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (err error) {
   145  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_getpeername_trampoline), uintptr(fd), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)))
   146  	if e1 != 0 {
   147  		err = errnoErr(e1)
   148  	}
   149  	return
   150  }
   151  
   152  func libc_getpeername_trampoline()
   153  
   154  //go:cgo_import_dynamic libc_getpeername getpeername "/usr/lib/libSystem.B.dylib"
   155  
   156  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   157  
   158  func getsockname(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (err error) {
   159  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_getsockname_trampoline), uintptr(fd), uintptr(unsafe.Pointer(rsa)), uintptr(unsafe.Pointer(addrlen)))
   160  	if e1 != 0 {
   161  		err = errnoErr(e1)
   162  	}
   163  	return
   164  }
   165  
   166  func libc_getsockname_trampoline()
   167  
   168  //go:cgo_import_dynamic libc_getsockname getsockname "/usr/lib/libSystem.B.dylib"
   169  
   170  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   171  
   172  func Shutdown(s int, how int) (err error) {
   173  	_, _, e1 := syscall(abi.FuncPCABI0(libc_shutdown_trampoline), uintptr(s), uintptr(how), 0)
   174  	if e1 != 0 {
   175  		err = errnoErr(e1)
   176  	}
   177  	return
   178  }
   179  
   180  func libc_shutdown_trampoline()
   181  
   182  //go:cgo_import_dynamic libc_shutdown shutdown "/usr/lib/libSystem.B.dylib"
   183  
   184  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   185  
   186  func socketpair(domain int, typ int, proto int, fd *[2]int32) (err error) {
   187  	_, _, e1 := rawSyscall6(abi.FuncPCABI0(libc_socketpair_trampoline), uintptr(domain), uintptr(typ), uintptr(proto), uintptr(unsafe.Pointer(fd)), 0, 0)
   188  	if e1 != 0 {
   189  		err = errnoErr(e1)
   190  	}
   191  	return
   192  }
   193  
   194  func libc_socketpair_trampoline()
   195  
   196  //go:cgo_import_dynamic libc_socketpair socketpair "/usr/lib/libSystem.B.dylib"
   197  
   198  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   199  
   200  func recvfrom(fd int, p []byte, flags int, from *RawSockaddrAny, fromlen *_Socklen) (n int, err error) {
   201  	var _p0 unsafe.Pointer
   202  	if len(p) > 0 {
   203  		_p0 = unsafe.Pointer(&p[0])
   204  	} else {
   205  		_p0 = unsafe.Pointer(&_zero)
   206  	}
   207  	r0, _, e1 := syscall6(abi.FuncPCABI0(libc_recvfrom_trampoline), uintptr(fd), uintptr(_p0), uintptr(len(p)), uintptr(flags), uintptr(unsafe.Pointer(from)), uintptr(unsafe.Pointer(fromlen)))
   208  	n = int(r0)
   209  	if e1 != 0 {
   210  		err = errnoErr(e1)
   211  	}
   212  	return
   213  }
   214  
   215  func libc_recvfrom_trampoline()
   216  
   217  //go:cgo_import_dynamic libc_recvfrom recvfrom "/usr/lib/libSystem.B.dylib"
   218  
   219  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   220  
   221  func sendto(s int, buf []byte, flags int, to unsafe.Pointer, addrlen _Socklen) (err error) {
   222  	var _p0 unsafe.Pointer
   223  	if len(buf) > 0 {
   224  		_p0 = unsafe.Pointer(&buf[0])
   225  	} else {
   226  		_p0 = unsafe.Pointer(&_zero)
   227  	}
   228  	_, _, e1 := syscall6(abi.FuncPCABI0(libc_sendto_trampoline), uintptr(s), uintptr(_p0), uintptr(len(buf)), uintptr(flags), uintptr(to), uintptr(addrlen))
   229  	if e1 != 0 {
   230  		err = errnoErr(e1)
   231  	}
   232  	return
   233  }
   234  
   235  func libc_sendto_trampoline()
   236  
   237  //go:cgo_import_dynamic libc_sendto sendto "/usr/lib/libSystem.B.dylib"
   238  
   239  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   240  
   241  func recvmsg(s int, msg *Msghdr, flags int) (n int, err error) {
   242  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_recvmsg_trampoline), uintptr(s), uintptr(unsafe.Pointer(msg)), uintptr(flags))
   243  	n = int(r0)
   244  	if e1 != 0 {
   245  		err = errnoErr(e1)
   246  	}
   247  	return
   248  }
   249  
   250  func libc_recvmsg_trampoline()
   251  
   252  //go:cgo_import_dynamic libc_recvmsg recvmsg "/usr/lib/libSystem.B.dylib"
   253  
   254  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   255  
   256  func sendmsg(s int, msg *Msghdr, flags int) (n int, err error) {
   257  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_sendmsg_trampoline), uintptr(s), uintptr(unsafe.Pointer(msg)), uintptr(flags))
   258  	n = int(r0)
   259  	if e1 != 0 {
   260  		err = errnoErr(e1)
   261  	}
   262  	return
   263  }
   264  
   265  func libc_sendmsg_trampoline()
   266  
   267  //go:cgo_import_dynamic libc_sendmsg sendmsg "/usr/lib/libSystem.B.dylib"
   268  
   269  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   270  
   271  func kevent(kq int, change unsafe.Pointer, nchange int, event unsafe.Pointer, nevent int, timeout *Timespec) (n int, err error) {
   272  	r0, _, e1 := syscall6(abi.FuncPCABI0(libc_kevent_trampoline), uintptr(kq), uintptr(change), uintptr(nchange), uintptr(event), uintptr(nevent), uintptr(unsafe.Pointer(timeout)))
   273  	n = int(r0)
   274  	if e1 != 0 {
   275  		err = errnoErr(e1)
   276  	}
   277  	return
   278  }
   279  
   280  func libc_kevent_trampoline()
   281  
   282  //go:cgo_import_dynamic libc_kevent kevent "/usr/lib/libSystem.B.dylib"
   283  
   284  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   285  
   286  func utimes(path string, timeval *[2]Timeval) (err error) {
   287  	var _p0 *byte
   288  	_p0, err = BytePtrFromString(path)
   289  	if err != nil {
   290  		return
   291  	}
   292  	_, _, e1 := syscall(abi.FuncPCABI0(libc_utimes_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(timeval)), 0)
   293  	if e1 != 0 {
   294  		err = errnoErr(e1)
   295  	}
   296  	return
   297  }
   298  
   299  func libc_utimes_trampoline()
   300  
   301  //go:cgo_import_dynamic libc_utimes utimes "/usr/lib/libSystem.B.dylib"
   302  
   303  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   304  
   305  func futimes(fd int, timeval *[2]Timeval) (err error) {
   306  	_, _, e1 := syscall(abi.FuncPCABI0(libc_futimes_trampoline), uintptr(fd), uintptr(unsafe.Pointer(timeval)), 0)
   307  	if e1 != 0 {
   308  		err = errnoErr(e1)
   309  	}
   310  	return
   311  }
   312  
   313  func libc_futimes_trampoline()
   314  
   315  //go:cgo_import_dynamic libc_futimes futimes "/usr/lib/libSystem.B.dylib"
   316  
   317  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   318  
   319  func fcntl(fd int, cmd int, arg int) (val int, err error) {
   320  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_fcntl_trampoline), uintptr(fd), uintptr(cmd), uintptr(arg))
   321  	val = int(r0)
   322  	if e1 != 0 {
   323  		err = errnoErr(e1)
   324  	}
   325  	return
   326  }
   327  
   328  func libc_fcntl_trampoline()
   329  
   330  //go:cgo_import_dynamic libc_fcntl fcntl "/usr/lib/libSystem.B.dylib"
   331  
   332  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   333  
   334  func pipe(p *[2]int32) (err error) {
   335  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_pipe_trampoline), uintptr(unsafe.Pointer(p)), 0, 0)
   336  	if e1 != 0 {
   337  		err = errnoErr(e1)
   338  	}
   339  	return
   340  }
   341  
   342  func libc_pipe_trampoline()
   343  
   344  //go:cgo_import_dynamic libc_pipe pipe "/usr/lib/libSystem.B.dylib"
   345  
   346  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   347  
   348  func kill(pid int, signum int, posix int) (err error) {
   349  	_, _, e1 := syscall(abi.FuncPCABI0(libc_kill_trampoline), uintptr(pid), uintptr(signum), uintptr(posix))
   350  	if e1 != 0 {
   351  		err = errnoErr(e1)
   352  	}
   353  	return
   354  }
   355  
   356  func libc_kill_trampoline()
   357  
   358  //go:cgo_import_dynamic libc_kill kill "/usr/lib/libSystem.B.dylib"
   359  
   360  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   361  
   362  func Access(path string, mode uint32) (err error) {
   363  	var _p0 *byte
   364  	_p0, err = BytePtrFromString(path)
   365  	if err != nil {
   366  		return
   367  	}
   368  	_, _, e1 := syscall(abi.FuncPCABI0(libc_access_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(mode), 0)
   369  	if e1 != 0 {
   370  		err = errnoErr(e1)
   371  	}
   372  	return
   373  }
   374  
   375  func libc_access_trampoline()
   376  
   377  //go:cgo_import_dynamic libc_access access "/usr/lib/libSystem.B.dylib"
   378  
   379  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   380  
   381  func Adjtime(delta *Timeval, olddelta *Timeval) (err error) {
   382  	_, _, e1 := syscall(abi.FuncPCABI0(libc_adjtime_trampoline), uintptr(unsafe.Pointer(delta)), uintptr(unsafe.Pointer(olddelta)), 0)
   383  	if e1 != 0 {
   384  		err = errnoErr(e1)
   385  	}
   386  	return
   387  }
   388  
   389  func libc_adjtime_trampoline()
   390  
   391  //go:cgo_import_dynamic libc_adjtime adjtime "/usr/lib/libSystem.B.dylib"
   392  
   393  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   394  
   395  func Chdir(path string) (err error) {
   396  	var _p0 *byte
   397  	_p0, err = BytePtrFromString(path)
   398  	if err != nil {
   399  		return
   400  	}
   401  	_, _, e1 := syscall(abi.FuncPCABI0(libc_chdir_trampoline), uintptr(unsafe.Pointer(_p0)), 0, 0)
   402  	if e1 != 0 {
   403  		err = errnoErr(e1)
   404  	}
   405  	return
   406  }
   407  
   408  func libc_chdir_trampoline()
   409  
   410  //go:cgo_import_dynamic libc_chdir chdir "/usr/lib/libSystem.B.dylib"
   411  
   412  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   413  
   414  func Chflags(path string, flags int) (err error) {
   415  	var _p0 *byte
   416  	_p0, err = BytePtrFromString(path)
   417  	if err != nil {
   418  		return
   419  	}
   420  	_, _, e1 := syscall(abi.FuncPCABI0(libc_chflags_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(flags), 0)
   421  	if e1 != 0 {
   422  		err = errnoErr(e1)
   423  	}
   424  	return
   425  }
   426  
   427  func libc_chflags_trampoline()
   428  
   429  //go:cgo_import_dynamic libc_chflags chflags "/usr/lib/libSystem.B.dylib"
   430  
   431  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   432  
   433  func Chmod(path string, mode uint32) (err error) {
   434  	var _p0 *byte
   435  	_p0, err = BytePtrFromString(path)
   436  	if err != nil {
   437  		return
   438  	}
   439  	_, _, e1 := syscall(abi.FuncPCABI0(libc_chmod_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(mode), 0)
   440  	if e1 != 0 {
   441  		err = errnoErr(e1)
   442  	}
   443  	return
   444  }
   445  
   446  func libc_chmod_trampoline()
   447  
   448  //go:cgo_import_dynamic libc_chmod chmod "/usr/lib/libSystem.B.dylib"
   449  
   450  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   451  
   452  func Chown(path string, uid int, gid int) (err error) {
   453  	var _p0 *byte
   454  	_p0, err = BytePtrFromString(path)
   455  	if err != nil {
   456  		return
   457  	}
   458  	_, _, e1 := syscall(abi.FuncPCABI0(libc_chown_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(uid), uintptr(gid))
   459  	if e1 != 0 {
   460  		err = errnoErr(e1)
   461  	}
   462  	return
   463  }
   464  
   465  func libc_chown_trampoline()
   466  
   467  //go:cgo_import_dynamic libc_chown chown "/usr/lib/libSystem.B.dylib"
   468  
   469  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   470  
   471  func Chroot(path string) (err error) {
   472  	var _p0 *byte
   473  	_p0, err = BytePtrFromString(path)
   474  	if err != nil {
   475  		return
   476  	}
   477  	_, _, e1 := syscall(abi.FuncPCABI0(libc_chroot_trampoline), uintptr(unsafe.Pointer(_p0)), 0, 0)
   478  	if e1 != 0 {
   479  		err = errnoErr(e1)
   480  	}
   481  	return
   482  }
   483  
   484  func libc_chroot_trampoline()
   485  
   486  //go:cgo_import_dynamic libc_chroot chroot "/usr/lib/libSystem.B.dylib"
   487  
   488  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   489  
   490  func Close(fd int) (err error) {
   491  	_, _, e1 := syscall(abi.FuncPCABI0(libc_close_trampoline), uintptr(fd), 0, 0)
   492  	if e1 != 0 {
   493  		err = errnoErr(e1)
   494  	}
   495  	return
   496  }
   497  
   498  func libc_close_trampoline()
   499  
   500  //go:cgo_import_dynamic libc_close close "/usr/lib/libSystem.B.dylib"
   501  
   502  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   503  
   504  func closedir(dir uintptr) (err error) {
   505  	_, _, e1 := syscall(abi.FuncPCABI0(libc_closedir_trampoline), uintptr(dir), 0, 0)
   506  	if e1 != 0 {
   507  		err = errnoErr(e1)
   508  	}
   509  	return
   510  }
   511  
   512  func libc_closedir_trampoline()
   513  
   514  //go:cgo_import_dynamic libc_closedir closedir "/usr/lib/libSystem.B.dylib"
   515  
   516  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   517  
   518  func Dup(fd int) (nfd int, err error) {
   519  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_dup_trampoline), uintptr(fd), 0, 0)
   520  	nfd = int(r0)
   521  	if e1 != 0 {
   522  		err = errnoErr(e1)
   523  	}
   524  	return
   525  }
   526  
   527  func libc_dup_trampoline()
   528  
   529  //go:cgo_import_dynamic libc_dup dup "/usr/lib/libSystem.B.dylib"
   530  
   531  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   532  
   533  func Dup2(from int, to int) (err error) {
   534  	_, _, e1 := syscall(abi.FuncPCABI0(libc_dup2_trampoline), uintptr(from), uintptr(to), 0)
   535  	if e1 != 0 {
   536  		err = errnoErr(e1)
   537  	}
   538  	return
   539  }
   540  
   541  func libc_dup2_trampoline()
   542  
   543  //go:cgo_import_dynamic libc_dup2 dup2 "/usr/lib/libSystem.B.dylib"
   544  
   545  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   546  
   547  func Exchangedata(path1 string, path2 string, options int) (err error) {
   548  	var _p0 *byte
   549  	_p0, err = BytePtrFromString(path1)
   550  	if err != nil {
   551  		return
   552  	}
   553  	var _p1 *byte
   554  	_p1, err = BytePtrFromString(path2)
   555  	if err != nil {
   556  		return
   557  	}
   558  	_, _, e1 := syscall(abi.FuncPCABI0(libc_exchangedata_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(options))
   559  	if e1 != 0 {
   560  		err = errnoErr(e1)
   561  	}
   562  	return
   563  }
   564  
   565  func libc_exchangedata_trampoline()
   566  
   567  //go:cgo_import_dynamic libc_exchangedata exchangedata "/usr/lib/libSystem.B.dylib"
   568  
   569  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   570  
   571  func Fchdir(fd int) (err error) {
   572  	_, _, e1 := syscall(abi.FuncPCABI0(libc_fchdir_trampoline), uintptr(fd), 0, 0)
   573  	if e1 != 0 {
   574  		err = errnoErr(e1)
   575  	}
   576  	return
   577  }
   578  
   579  func libc_fchdir_trampoline()
   580  
   581  //go:cgo_import_dynamic libc_fchdir fchdir "/usr/lib/libSystem.B.dylib"
   582  
   583  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   584  
   585  func Fchflags(fd int, flags int) (err error) {
   586  	_, _, e1 := syscall(abi.FuncPCABI0(libc_fchflags_trampoline), uintptr(fd), uintptr(flags), 0)
   587  	if e1 != 0 {
   588  		err = errnoErr(e1)
   589  	}
   590  	return
   591  }
   592  
   593  func libc_fchflags_trampoline()
   594  
   595  //go:cgo_import_dynamic libc_fchflags fchflags "/usr/lib/libSystem.B.dylib"
   596  
   597  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   598  
   599  func Fchmod(fd int, mode uint32) (err error) {
   600  	_, _, e1 := syscall(abi.FuncPCABI0(libc_fchmod_trampoline), uintptr(fd), uintptr(mode), 0)
   601  	if e1 != 0 {
   602  		err = errnoErr(e1)
   603  	}
   604  	return
   605  }
   606  
   607  func libc_fchmod_trampoline()
   608  
   609  //go:cgo_import_dynamic libc_fchmod fchmod "/usr/lib/libSystem.B.dylib"
   610  
   611  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   612  
   613  func Fchown(fd int, uid int, gid int) (err error) {
   614  	_, _, e1 := syscall(abi.FuncPCABI0(libc_fchown_trampoline), uintptr(fd), uintptr(uid), uintptr(gid))
   615  	if e1 != 0 {
   616  		err = errnoErr(e1)
   617  	}
   618  	return
   619  }
   620  
   621  func libc_fchown_trampoline()
   622  
   623  //go:cgo_import_dynamic libc_fchown fchown "/usr/lib/libSystem.B.dylib"
   624  
   625  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   626  
   627  func Flock(fd int, how int) (err error) {
   628  	_, _, e1 := syscall(abi.FuncPCABI0(libc_flock_trampoline), uintptr(fd), uintptr(how), 0)
   629  	if e1 != 0 {
   630  		err = errnoErr(e1)
   631  	}
   632  	return
   633  }
   634  
   635  func libc_flock_trampoline()
   636  
   637  //go:cgo_import_dynamic libc_flock flock "/usr/lib/libSystem.B.dylib"
   638  
   639  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   640  
   641  func Fpathconf(fd int, name int) (val int, err error) {
   642  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_fpathconf_trampoline), uintptr(fd), uintptr(name), 0)
   643  	val = int(r0)
   644  	if e1 != 0 {
   645  		err = errnoErr(e1)
   646  	}
   647  	return
   648  }
   649  
   650  func libc_fpathconf_trampoline()
   651  
   652  //go:cgo_import_dynamic libc_fpathconf fpathconf "/usr/lib/libSystem.B.dylib"
   653  
   654  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   655  
   656  func Fsync(fd int) (err error) {
   657  	_, _, e1 := syscall(abi.FuncPCABI0(libc_fsync_trampoline), uintptr(fd), 0, 0)
   658  	if e1 != 0 {
   659  		err = errnoErr(e1)
   660  	}
   661  	return
   662  }
   663  
   664  func libc_fsync_trampoline()
   665  
   666  //go:cgo_import_dynamic libc_fsync fsync "/usr/lib/libSystem.B.dylib"
   667  
   668  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   669  
   670  func Ftruncate(fd int, length int64) (err error) {
   671  	_, _, e1 := syscall(abi.FuncPCABI0(libc_ftruncate_trampoline), uintptr(fd), uintptr(length), 0)
   672  	if e1 != 0 {
   673  		err = errnoErr(e1)
   674  	}
   675  	return
   676  }
   677  
   678  func libc_ftruncate_trampoline()
   679  
   680  //go:cgo_import_dynamic libc_ftruncate ftruncate "/usr/lib/libSystem.B.dylib"
   681  
   682  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   683  
   684  func Getdtablesize() (size int) {
   685  	r0, _, _ := syscall(abi.FuncPCABI0(libc_getdtablesize_trampoline), 0, 0, 0)
   686  	size = int(r0)
   687  	return
   688  }
   689  
   690  func libc_getdtablesize_trampoline()
   691  
   692  //go:cgo_import_dynamic libc_getdtablesize getdtablesize "/usr/lib/libSystem.B.dylib"
   693  
   694  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   695  
   696  func Getegid() (egid int) {
   697  	r0, _, _ := rawSyscall(abi.FuncPCABI0(libc_getegid_trampoline), 0, 0, 0)
   698  	egid = int(r0)
   699  	return
   700  }
   701  
   702  func libc_getegid_trampoline()
   703  
   704  //go:cgo_import_dynamic libc_getegid getegid "/usr/lib/libSystem.B.dylib"
   705  
   706  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   707  
   708  func Geteuid() (uid int) {
   709  	r0, _, _ := rawSyscall(abi.FuncPCABI0(libc_geteuid_trampoline), 0, 0, 0)
   710  	uid = int(r0)
   711  	return
   712  }
   713  
   714  func libc_geteuid_trampoline()
   715  
   716  //go:cgo_import_dynamic libc_geteuid geteuid "/usr/lib/libSystem.B.dylib"
   717  
   718  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   719  
   720  func Getgid() (gid int) {
   721  	r0, _, _ := rawSyscall(abi.FuncPCABI0(libc_getgid_trampoline), 0, 0, 0)
   722  	gid = int(r0)
   723  	return
   724  }
   725  
   726  func libc_getgid_trampoline()
   727  
   728  //go:cgo_import_dynamic libc_getgid getgid "/usr/lib/libSystem.B.dylib"
   729  
   730  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   731  
   732  func Getpgid(pid int) (pgid int, err error) {
   733  	r0, _, e1 := rawSyscall(abi.FuncPCABI0(libc_getpgid_trampoline), uintptr(pid), 0, 0)
   734  	pgid = int(r0)
   735  	if e1 != 0 {
   736  		err = errnoErr(e1)
   737  	}
   738  	return
   739  }
   740  
   741  func libc_getpgid_trampoline()
   742  
   743  //go:cgo_import_dynamic libc_getpgid getpgid "/usr/lib/libSystem.B.dylib"
   744  
   745  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   746  
   747  func Getpgrp() (pgrp int) {
   748  	r0, _, _ := rawSyscall(abi.FuncPCABI0(libc_getpgrp_trampoline), 0, 0, 0)
   749  	pgrp = int(r0)
   750  	return
   751  }
   752  
   753  func libc_getpgrp_trampoline()
   754  
   755  //go:cgo_import_dynamic libc_getpgrp getpgrp "/usr/lib/libSystem.B.dylib"
   756  
   757  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   758  
   759  func Getpid() (pid int) {
   760  	r0, _, _ := rawSyscall(abi.FuncPCABI0(libc_getpid_trampoline), 0, 0, 0)
   761  	pid = int(r0)
   762  	return
   763  }
   764  
   765  func libc_getpid_trampoline()
   766  
   767  //go:cgo_import_dynamic libc_getpid getpid "/usr/lib/libSystem.B.dylib"
   768  
   769  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   770  
   771  func Getppid() (ppid int) {
   772  	r0, _, _ := rawSyscall(abi.FuncPCABI0(libc_getppid_trampoline), 0, 0, 0)
   773  	ppid = int(r0)
   774  	return
   775  }
   776  
   777  func libc_getppid_trampoline()
   778  
   779  //go:cgo_import_dynamic libc_getppid getppid "/usr/lib/libSystem.B.dylib"
   780  
   781  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   782  
   783  func Getpriority(which int, who int) (prio int, err error) {
   784  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_getpriority_trampoline), uintptr(which), uintptr(who), 0)
   785  	prio = int(r0)
   786  	if e1 != 0 {
   787  		err = errnoErr(e1)
   788  	}
   789  	return
   790  }
   791  
   792  func libc_getpriority_trampoline()
   793  
   794  //go:cgo_import_dynamic libc_getpriority getpriority "/usr/lib/libSystem.B.dylib"
   795  
   796  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   797  
   798  func Getrlimit(which int, lim *Rlimit) (err error) {
   799  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_getrlimit_trampoline), uintptr(which), uintptr(unsafe.Pointer(lim)), 0)
   800  	if e1 != 0 {
   801  		err = errnoErr(e1)
   802  	}
   803  	return
   804  }
   805  
   806  func libc_getrlimit_trampoline()
   807  
   808  //go:cgo_import_dynamic libc_getrlimit getrlimit "/usr/lib/libSystem.B.dylib"
   809  
   810  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   811  
   812  func Getrusage(who int, rusage *Rusage) (err error) {
   813  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_getrusage_trampoline), uintptr(who), uintptr(unsafe.Pointer(rusage)), 0)
   814  	if e1 != 0 {
   815  		err = errnoErr(e1)
   816  	}
   817  	return
   818  }
   819  
   820  func libc_getrusage_trampoline()
   821  
   822  //go:cgo_import_dynamic libc_getrusage getrusage "/usr/lib/libSystem.B.dylib"
   823  
   824  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   825  
   826  func Getsid(pid int) (sid int, err error) {
   827  	r0, _, e1 := rawSyscall(abi.FuncPCABI0(libc_getsid_trampoline), uintptr(pid), 0, 0)
   828  	sid = int(r0)
   829  	if e1 != 0 {
   830  		err = errnoErr(e1)
   831  	}
   832  	return
   833  }
   834  
   835  func libc_getsid_trampoline()
   836  
   837  //go:cgo_import_dynamic libc_getsid getsid "/usr/lib/libSystem.B.dylib"
   838  
   839  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   840  
   841  func Getuid() (uid int) {
   842  	r0, _, _ := rawSyscall(abi.FuncPCABI0(libc_getuid_trampoline), 0, 0, 0)
   843  	uid = int(r0)
   844  	return
   845  }
   846  
   847  func libc_getuid_trampoline()
   848  
   849  //go:cgo_import_dynamic libc_getuid getuid "/usr/lib/libSystem.B.dylib"
   850  
   851  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   852  
   853  func Issetugid() (tainted bool) {
   854  	r0, _, _ := rawSyscall(abi.FuncPCABI0(libc_issetugid_trampoline), 0, 0, 0)
   855  	tainted = bool(r0 != 0)
   856  	return
   857  }
   858  
   859  func libc_issetugid_trampoline()
   860  
   861  //go:cgo_import_dynamic libc_issetugid issetugid "/usr/lib/libSystem.B.dylib"
   862  
   863  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   864  
   865  func Kqueue() (fd int, err error) {
   866  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_kqueue_trampoline), 0, 0, 0)
   867  	fd = int(r0)
   868  	if e1 != 0 {
   869  		err = errnoErr(e1)
   870  	}
   871  	return
   872  }
   873  
   874  func libc_kqueue_trampoline()
   875  
   876  //go:cgo_import_dynamic libc_kqueue kqueue "/usr/lib/libSystem.B.dylib"
   877  
   878  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   879  
   880  func Lchown(path string, uid int, gid int) (err error) {
   881  	var _p0 *byte
   882  	_p0, err = BytePtrFromString(path)
   883  	if err != nil {
   884  		return
   885  	}
   886  	_, _, e1 := syscall(abi.FuncPCABI0(libc_lchown_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(uid), uintptr(gid))
   887  	if e1 != 0 {
   888  		err = errnoErr(e1)
   889  	}
   890  	return
   891  }
   892  
   893  func libc_lchown_trampoline()
   894  
   895  //go:cgo_import_dynamic libc_lchown lchown "/usr/lib/libSystem.B.dylib"
   896  
   897  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   898  
   899  func Link(path string, link string) (err error) {
   900  	var _p0 *byte
   901  	_p0, err = BytePtrFromString(path)
   902  	if err != nil {
   903  		return
   904  	}
   905  	var _p1 *byte
   906  	_p1, err = BytePtrFromString(link)
   907  	if err != nil {
   908  		return
   909  	}
   910  	_, _, e1 := syscall(abi.FuncPCABI0(libc_link_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), 0)
   911  	if e1 != 0 {
   912  		err = errnoErr(e1)
   913  	}
   914  	return
   915  }
   916  
   917  func libc_link_trampoline()
   918  
   919  //go:cgo_import_dynamic libc_link link "/usr/lib/libSystem.B.dylib"
   920  
   921  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   922  
   923  func Listen(s int, backlog int) (err error) {
   924  	_, _, e1 := syscall(abi.FuncPCABI0(libc_listen_trampoline), uintptr(s), uintptr(backlog), 0)
   925  	if e1 != 0 {
   926  		err = errnoErr(e1)
   927  	}
   928  	return
   929  }
   930  
   931  func libc_listen_trampoline()
   932  
   933  //go:cgo_import_dynamic libc_listen listen "/usr/lib/libSystem.B.dylib"
   934  
   935  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   936  
   937  func Mkdir(path string, mode uint32) (err error) {
   938  	var _p0 *byte
   939  	_p0, err = BytePtrFromString(path)
   940  	if err != nil {
   941  		return
   942  	}
   943  	_, _, e1 := syscall(abi.FuncPCABI0(libc_mkdir_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(mode), 0)
   944  	if e1 != 0 {
   945  		err = errnoErr(e1)
   946  	}
   947  	return
   948  }
   949  
   950  func libc_mkdir_trampoline()
   951  
   952  //go:cgo_import_dynamic libc_mkdir mkdir "/usr/lib/libSystem.B.dylib"
   953  
   954  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   955  
   956  func Mkfifo(path string, mode uint32) (err error) {
   957  	var _p0 *byte
   958  	_p0, err = BytePtrFromString(path)
   959  	if err != nil {
   960  		return
   961  	}
   962  	_, _, e1 := syscall(abi.FuncPCABI0(libc_mkfifo_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(mode), 0)
   963  	if e1 != 0 {
   964  		err = errnoErr(e1)
   965  	}
   966  	return
   967  }
   968  
   969  func libc_mkfifo_trampoline()
   970  
   971  //go:cgo_import_dynamic libc_mkfifo mkfifo "/usr/lib/libSystem.B.dylib"
   972  
   973  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   974  
   975  func Mknod(path string, mode uint32, dev int) (err error) {
   976  	var _p0 *byte
   977  	_p0, err = BytePtrFromString(path)
   978  	if err != nil {
   979  		return
   980  	}
   981  	_, _, e1 := syscall(abi.FuncPCABI0(libc_mknod_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(mode), uintptr(dev))
   982  	if e1 != 0 {
   983  		err = errnoErr(e1)
   984  	}
   985  	return
   986  }
   987  
   988  func libc_mknod_trampoline()
   989  
   990  //go:cgo_import_dynamic libc_mknod mknod "/usr/lib/libSystem.B.dylib"
   991  
   992  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
   993  
   994  func Mlock(b []byte) (err error) {
   995  	var _p0 unsafe.Pointer
   996  	if len(b) > 0 {
   997  		_p0 = unsafe.Pointer(&b[0])
   998  	} else {
   999  		_p0 = unsafe.Pointer(&_zero)
  1000  	}
  1001  	_, _, e1 := syscall(abi.FuncPCABI0(libc_mlock_trampoline), uintptr(_p0), uintptr(len(b)), 0)
  1002  	if e1 != 0 {
  1003  		err = errnoErr(e1)
  1004  	}
  1005  	return
  1006  }
  1007  
  1008  func libc_mlock_trampoline()
  1009  
  1010  //go:cgo_import_dynamic libc_mlock mlock "/usr/lib/libSystem.B.dylib"
  1011  
  1012  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1013  
  1014  func Mlockall(flags int) (err error) {
  1015  	_, _, e1 := syscall(abi.FuncPCABI0(libc_mlockall_trampoline), uintptr(flags), 0, 0)
  1016  	if e1 != 0 {
  1017  		err = errnoErr(e1)
  1018  	}
  1019  	return
  1020  }
  1021  
  1022  func libc_mlockall_trampoline()
  1023  
  1024  //go:cgo_import_dynamic libc_mlockall mlockall "/usr/lib/libSystem.B.dylib"
  1025  
  1026  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1027  
  1028  func Mprotect(b []byte, prot int) (err error) {
  1029  	var _p0 unsafe.Pointer
  1030  	if len(b) > 0 {
  1031  		_p0 = unsafe.Pointer(&b[0])
  1032  	} else {
  1033  		_p0 = unsafe.Pointer(&_zero)
  1034  	}
  1035  	_, _, e1 := syscall(abi.FuncPCABI0(libc_mprotect_trampoline), uintptr(_p0), uintptr(len(b)), uintptr(prot))
  1036  	if e1 != 0 {
  1037  		err = errnoErr(e1)
  1038  	}
  1039  	return
  1040  }
  1041  
  1042  func libc_mprotect_trampoline()
  1043  
  1044  //go:cgo_import_dynamic libc_mprotect mprotect "/usr/lib/libSystem.B.dylib"
  1045  
  1046  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1047  
  1048  func Munlock(b []byte) (err error) {
  1049  	var _p0 unsafe.Pointer
  1050  	if len(b) > 0 {
  1051  		_p0 = unsafe.Pointer(&b[0])
  1052  	} else {
  1053  		_p0 = unsafe.Pointer(&_zero)
  1054  	}
  1055  	_, _, e1 := syscall(abi.FuncPCABI0(libc_munlock_trampoline), uintptr(_p0), uintptr(len(b)), 0)
  1056  	if e1 != 0 {
  1057  		err = errnoErr(e1)
  1058  	}
  1059  	return
  1060  }
  1061  
  1062  func libc_munlock_trampoline()
  1063  
  1064  //go:cgo_import_dynamic libc_munlock munlock "/usr/lib/libSystem.B.dylib"
  1065  
  1066  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1067  
  1068  func Munlockall() (err error) {
  1069  	_, _, e1 := syscall(abi.FuncPCABI0(libc_munlockall_trampoline), 0, 0, 0)
  1070  	if e1 != 0 {
  1071  		err = errnoErr(e1)
  1072  	}
  1073  	return
  1074  }
  1075  
  1076  func libc_munlockall_trampoline()
  1077  
  1078  //go:cgo_import_dynamic libc_munlockall munlockall "/usr/lib/libSystem.B.dylib"
  1079  
  1080  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1081  
  1082  func Open(path string, mode int, perm uint32) (fd int, err error) {
  1083  	var _p0 *byte
  1084  	_p0, err = BytePtrFromString(path)
  1085  	if err != nil {
  1086  		return
  1087  	}
  1088  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_open_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(mode), uintptr(perm))
  1089  	fd = int(r0)
  1090  	if e1 != 0 {
  1091  		err = errnoErr(e1)
  1092  	}
  1093  	return
  1094  }
  1095  
  1096  func libc_open_trampoline()
  1097  
  1098  //go:cgo_import_dynamic libc_open open "/usr/lib/libSystem.B.dylib"
  1099  
  1100  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1101  
  1102  func Pathconf(path string, name int) (val int, err error) {
  1103  	var _p0 *byte
  1104  	_p0, err = BytePtrFromString(path)
  1105  	if err != nil {
  1106  		return
  1107  	}
  1108  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_pathconf_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(name), 0)
  1109  	val = int(r0)
  1110  	if e1 != 0 {
  1111  		err = errnoErr(e1)
  1112  	}
  1113  	return
  1114  }
  1115  
  1116  func libc_pathconf_trampoline()
  1117  
  1118  //go:cgo_import_dynamic libc_pathconf pathconf "/usr/lib/libSystem.B.dylib"
  1119  
  1120  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1121  
  1122  func Pread(fd int, p []byte, offset int64) (n int, err error) {
  1123  	var _p0 unsafe.Pointer
  1124  	if len(p) > 0 {
  1125  		_p0 = unsafe.Pointer(&p[0])
  1126  	} else {
  1127  		_p0 = unsafe.Pointer(&_zero)
  1128  	}
  1129  	r0, _, e1 := syscall6(abi.FuncPCABI0(libc_pread_trampoline), uintptr(fd), uintptr(_p0), uintptr(len(p)), uintptr(offset), 0, 0)
  1130  	n = int(r0)
  1131  	if e1 != 0 {
  1132  		err = errnoErr(e1)
  1133  	}
  1134  	return
  1135  }
  1136  
  1137  func libc_pread_trampoline()
  1138  
  1139  //go:cgo_import_dynamic libc_pread pread "/usr/lib/libSystem.B.dylib"
  1140  
  1141  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1142  
  1143  func Pwrite(fd int, p []byte, offset int64) (n int, err error) {
  1144  	var _p0 unsafe.Pointer
  1145  	if len(p) > 0 {
  1146  		_p0 = unsafe.Pointer(&p[0])
  1147  	} else {
  1148  		_p0 = unsafe.Pointer(&_zero)
  1149  	}
  1150  	r0, _, e1 := syscall6(abi.FuncPCABI0(libc_pwrite_trampoline), uintptr(fd), uintptr(_p0), uintptr(len(p)), uintptr(offset), 0, 0)
  1151  	n = int(r0)
  1152  	if e1 != 0 {
  1153  		err = errnoErr(e1)
  1154  	}
  1155  	return
  1156  }
  1157  
  1158  func libc_pwrite_trampoline()
  1159  
  1160  //go:cgo_import_dynamic libc_pwrite pwrite "/usr/lib/libSystem.B.dylib"
  1161  
  1162  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1163  
  1164  func read(fd int, p []byte) (n int, err error) {
  1165  	var _p0 unsafe.Pointer
  1166  	if len(p) > 0 {
  1167  		_p0 = unsafe.Pointer(&p[0])
  1168  	} else {
  1169  		_p0 = unsafe.Pointer(&_zero)
  1170  	}
  1171  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_read_trampoline), uintptr(fd), uintptr(_p0), uintptr(len(p)))
  1172  	n = int(r0)
  1173  	if e1 != 0 {
  1174  		err = errnoErr(e1)
  1175  	}
  1176  	return
  1177  }
  1178  
  1179  func libc_read_trampoline()
  1180  
  1181  //go:cgo_import_dynamic libc_read read "/usr/lib/libSystem.B.dylib"
  1182  
  1183  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1184  
  1185  func readdir_r(dir uintptr, entry *Dirent, result **Dirent) (res Errno) {
  1186  	r0, _, _ := syscall(abi.FuncPCABI0(libc_readdir_r_trampoline), uintptr(dir), uintptr(unsafe.Pointer(entry)), uintptr(unsafe.Pointer(result)))
  1187  	res = Errno(r0)
  1188  	return
  1189  }
  1190  
  1191  func libc_readdir_r_trampoline()
  1192  
  1193  //go:cgo_import_dynamic libc_readdir_r readdir_r "/usr/lib/libSystem.B.dylib"
  1194  
  1195  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1196  
  1197  func Readlink(path string, buf []byte) (n int, err error) {
  1198  	var _p0 *byte
  1199  	_p0, err = BytePtrFromString(path)
  1200  	if err != nil {
  1201  		return
  1202  	}
  1203  	var _p1 unsafe.Pointer
  1204  	if len(buf) > 0 {
  1205  		_p1 = unsafe.Pointer(&buf[0])
  1206  	} else {
  1207  		_p1 = unsafe.Pointer(&_zero)
  1208  	}
  1209  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_readlink_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(_p1), uintptr(len(buf)))
  1210  	n = int(r0)
  1211  	if e1 != 0 {
  1212  		err = errnoErr(e1)
  1213  	}
  1214  	return
  1215  }
  1216  
  1217  func libc_readlink_trampoline()
  1218  
  1219  //go:cgo_import_dynamic libc_readlink readlink "/usr/lib/libSystem.B.dylib"
  1220  
  1221  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1222  
  1223  func Rename(from string, to string) (err error) {
  1224  	var _p0 *byte
  1225  	_p0, err = BytePtrFromString(from)
  1226  	if err != nil {
  1227  		return
  1228  	}
  1229  	var _p1 *byte
  1230  	_p1, err = BytePtrFromString(to)
  1231  	if err != nil {
  1232  		return
  1233  	}
  1234  	_, _, e1 := syscall(abi.FuncPCABI0(libc_rename_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), 0)
  1235  	if e1 != 0 {
  1236  		err = errnoErr(e1)
  1237  	}
  1238  	return
  1239  }
  1240  
  1241  func libc_rename_trampoline()
  1242  
  1243  //go:cgo_import_dynamic libc_rename rename "/usr/lib/libSystem.B.dylib"
  1244  
  1245  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1246  
  1247  func Revoke(path string) (err error) {
  1248  	var _p0 *byte
  1249  	_p0, err = BytePtrFromString(path)
  1250  	if err != nil {
  1251  		return
  1252  	}
  1253  	_, _, e1 := syscall(abi.FuncPCABI0(libc_revoke_trampoline), uintptr(unsafe.Pointer(_p0)), 0, 0)
  1254  	if e1 != 0 {
  1255  		err = errnoErr(e1)
  1256  	}
  1257  	return
  1258  }
  1259  
  1260  func libc_revoke_trampoline()
  1261  
  1262  //go:cgo_import_dynamic libc_revoke revoke "/usr/lib/libSystem.B.dylib"
  1263  
  1264  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1265  
  1266  func Rmdir(path string) (err error) {
  1267  	var _p0 *byte
  1268  	_p0, err = BytePtrFromString(path)
  1269  	if err != nil {
  1270  		return
  1271  	}
  1272  	_, _, e1 := syscall(abi.FuncPCABI0(libc_rmdir_trampoline), uintptr(unsafe.Pointer(_p0)), 0, 0)
  1273  	if e1 != 0 {
  1274  		err = errnoErr(e1)
  1275  	}
  1276  	return
  1277  }
  1278  
  1279  func libc_rmdir_trampoline()
  1280  
  1281  //go:cgo_import_dynamic libc_rmdir rmdir "/usr/lib/libSystem.B.dylib"
  1282  
  1283  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1284  
  1285  func Seek(fd int, offset int64, whence int) (newoffset int64, err error) {
  1286  	r0, _, e1 := syscallX(abi.FuncPCABI0(libc_lseek_trampoline), uintptr(fd), uintptr(offset), uintptr(whence))
  1287  	newoffset = int64(r0)
  1288  	if e1 != 0 {
  1289  		err = errnoErr(e1)
  1290  	}
  1291  	return
  1292  }
  1293  
  1294  func libc_lseek_trampoline()
  1295  
  1296  //go:cgo_import_dynamic libc_lseek lseek "/usr/lib/libSystem.B.dylib"
  1297  
  1298  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1299  
  1300  func Select(n int, r *FdSet, w *FdSet, e *FdSet, timeout *Timeval) (err error) {
  1301  	_, _, e1 := syscall6(abi.FuncPCABI0(libc_select_trampoline), uintptr(n), uintptr(unsafe.Pointer(r)), uintptr(unsafe.Pointer(w)), uintptr(unsafe.Pointer(e)), uintptr(unsafe.Pointer(timeout)), 0)
  1302  	if e1 != 0 {
  1303  		err = errnoErr(e1)
  1304  	}
  1305  	return
  1306  }
  1307  
  1308  func libc_select_trampoline()
  1309  
  1310  //go:cgo_import_dynamic libc_select select "/usr/lib/libSystem.B.dylib"
  1311  
  1312  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1313  
  1314  func Setegid(egid int) (err error) {
  1315  	_, _, e1 := syscall(abi.FuncPCABI0(libc_setegid_trampoline), uintptr(egid), 0, 0)
  1316  	if e1 != 0 {
  1317  		err = errnoErr(e1)
  1318  	}
  1319  	return
  1320  }
  1321  
  1322  func libc_setegid_trampoline()
  1323  
  1324  //go:cgo_import_dynamic libc_setegid setegid "/usr/lib/libSystem.B.dylib"
  1325  
  1326  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1327  
  1328  func Seteuid(euid int) (err error) {
  1329  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_seteuid_trampoline), uintptr(euid), 0, 0)
  1330  	if e1 != 0 {
  1331  		err = errnoErr(e1)
  1332  	}
  1333  	return
  1334  }
  1335  
  1336  func libc_seteuid_trampoline()
  1337  
  1338  //go:cgo_import_dynamic libc_seteuid seteuid "/usr/lib/libSystem.B.dylib"
  1339  
  1340  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1341  
  1342  func Setgid(gid int) (err error) {
  1343  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_setgid_trampoline), uintptr(gid), 0, 0)
  1344  	if e1 != 0 {
  1345  		err = errnoErr(e1)
  1346  	}
  1347  	return
  1348  }
  1349  
  1350  func libc_setgid_trampoline()
  1351  
  1352  //go:cgo_import_dynamic libc_setgid setgid "/usr/lib/libSystem.B.dylib"
  1353  
  1354  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1355  
  1356  func Setlogin(name string) (err error) {
  1357  	var _p0 *byte
  1358  	_p0, err = BytePtrFromString(name)
  1359  	if err != nil {
  1360  		return
  1361  	}
  1362  	_, _, e1 := syscall(abi.FuncPCABI0(libc_setlogin_trampoline), uintptr(unsafe.Pointer(_p0)), 0, 0)
  1363  	if e1 != 0 {
  1364  		err = errnoErr(e1)
  1365  	}
  1366  	return
  1367  }
  1368  
  1369  func libc_setlogin_trampoline()
  1370  
  1371  //go:cgo_import_dynamic libc_setlogin setlogin "/usr/lib/libSystem.B.dylib"
  1372  
  1373  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1374  
  1375  func Setpgid(pid int, pgid int) (err error) {
  1376  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_setpgid_trampoline), uintptr(pid), uintptr(pgid), 0)
  1377  	if e1 != 0 {
  1378  		err = errnoErr(e1)
  1379  	}
  1380  	return
  1381  }
  1382  
  1383  func libc_setpgid_trampoline()
  1384  
  1385  //go:cgo_import_dynamic libc_setpgid setpgid "/usr/lib/libSystem.B.dylib"
  1386  
  1387  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1388  
  1389  func Setpriority(which int, who int, prio int) (err error) {
  1390  	_, _, e1 := syscall(abi.FuncPCABI0(libc_setpriority_trampoline), uintptr(which), uintptr(who), uintptr(prio))
  1391  	if e1 != 0 {
  1392  		err = errnoErr(e1)
  1393  	}
  1394  	return
  1395  }
  1396  
  1397  func libc_setpriority_trampoline()
  1398  
  1399  //go:cgo_import_dynamic libc_setpriority setpriority "/usr/lib/libSystem.B.dylib"
  1400  
  1401  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1402  
  1403  func Setprivexec(flag int) (err error) {
  1404  	_, _, e1 := syscall(abi.FuncPCABI0(libc_setprivexec_trampoline), uintptr(flag), 0, 0)
  1405  	if e1 != 0 {
  1406  		err = errnoErr(e1)
  1407  	}
  1408  	return
  1409  }
  1410  
  1411  func libc_setprivexec_trampoline()
  1412  
  1413  //go:cgo_import_dynamic libc_setprivexec setprivexec "/usr/lib/libSystem.B.dylib"
  1414  
  1415  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1416  
  1417  func Setregid(rgid int, egid int) (err error) {
  1418  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_setregid_trampoline), uintptr(rgid), uintptr(egid), 0)
  1419  	if e1 != 0 {
  1420  		err = errnoErr(e1)
  1421  	}
  1422  	return
  1423  }
  1424  
  1425  func libc_setregid_trampoline()
  1426  
  1427  //go:cgo_import_dynamic libc_setregid setregid "/usr/lib/libSystem.B.dylib"
  1428  
  1429  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1430  
  1431  func Setreuid(ruid int, euid int) (err error) {
  1432  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_setreuid_trampoline), uintptr(ruid), uintptr(euid), 0)
  1433  	if e1 != 0 {
  1434  		err = errnoErr(e1)
  1435  	}
  1436  	return
  1437  }
  1438  
  1439  func libc_setreuid_trampoline()
  1440  
  1441  //go:cgo_import_dynamic libc_setreuid setreuid "/usr/lib/libSystem.B.dylib"
  1442  
  1443  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1444  
  1445  func Setrlimit(which int, lim *Rlimit) (err error) {
  1446  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_setrlimit_trampoline), uintptr(which), uintptr(unsafe.Pointer(lim)), 0)
  1447  	if e1 != 0 {
  1448  		err = errnoErr(e1)
  1449  	}
  1450  	return
  1451  }
  1452  
  1453  func libc_setrlimit_trampoline()
  1454  
  1455  //go:cgo_import_dynamic libc_setrlimit setrlimit "/usr/lib/libSystem.B.dylib"
  1456  
  1457  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1458  
  1459  func Setsid() (pid int, err error) {
  1460  	r0, _, e1 := rawSyscall(abi.FuncPCABI0(libc_setsid_trampoline), 0, 0, 0)
  1461  	pid = int(r0)
  1462  	if e1 != 0 {
  1463  		err = errnoErr(e1)
  1464  	}
  1465  	return
  1466  }
  1467  
  1468  func libc_setsid_trampoline()
  1469  
  1470  //go:cgo_import_dynamic libc_setsid setsid "/usr/lib/libSystem.B.dylib"
  1471  
  1472  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1473  
  1474  func Settimeofday(tp *Timeval) (err error) {
  1475  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_settimeofday_trampoline), uintptr(unsafe.Pointer(tp)), 0, 0)
  1476  	if e1 != 0 {
  1477  		err = errnoErr(e1)
  1478  	}
  1479  	return
  1480  }
  1481  
  1482  func libc_settimeofday_trampoline()
  1483  
  1484  //go:cgo_import_dynamic libc_settimeofday settimeofday "/usr/lib/libSystem.B.dylib"
  1485  
  1486  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1487  
  1488  func Setuid(uid int) (err error) {
  1489  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_setuid_trampoline), uintptr(uid), 0, 0)
  1490  	if e1 != 0 {
  1491  		err = errnoErr(e1)
  1492  	}
  1493  	return
  1494  }
  1495  
  1496  func libc_setuid_trampoline()
  1497  
  1498  //go:cgo_import_dynamic libc_setuid setuid "/usr/lib/libSystem.B.dylib"
  1499  
  1500  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1501  
  1502  func Symlink(path string, link string) (err error) {
  1503  	var _p0 *byte
  1504  	_p0, err = BytePtrFromString(path)
  1505  	if err != nil {
  1506  		return
  1507  	}
  1508  	var _p1 *byte
  1509  	_p1, err = BytePtrFromString(link)
  1510  	if err != nil {
  1511  		return
  1512  	}
  1513  	_, _, e1 := syscall(abi.FuncPCABI0(libc_symlink_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), 0)
  1514  	if e1 != 0 {
  1515  		err = errnoErr(e1)
  1516  	}
  1517  	return
  1518  }
  1519  
  1520  func libc_symlink_trampoline()
  1521  
  1522  //go:cgo_import_dynamic libc_symlink symlink "/usr/lib/libSystem.B.dylib"
  1523  
  1524  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1525  
  1526  func Sync() (err error) {
  1527  	_, _, e1 := syscall(abi.FuncPCABI0(libc_sync_trampoline), 0, 0, 0)
  1528  	if e1 != 0 {
  1529  		err = errnoErr(e1)
  1530  	}
  1531  	return
  1532  }
  1533  
  1534  func libc_sync_trampoline()
  1535  
  1536  //go:cgo_import_dynamic libc_sync sync "/usr/lib/libSystem.B.dylib"
  1537  
  1538  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1539  
  1540  func Truncate(path string, length int64) (err error) {
  1541  	var _p0 *byte
  1542  	_p0, err = BytePtrFromString(path)
  1543  	if err != nil {
  1544  		return
  1545  	}
  1546  	_, _, e1 := syscall(abi.FuncPCABI0(libc_truncate_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(length), 0)
  1547  	if e1 != 0 {
  1548  		err = errnoErr(e1)
  1549  	}
  1550  	return
  1551  }
  1552  
  1553  func libc_truncate_trampoline()
  1554  
  1555  //go:cgo_import_dynamic libc_truncate truncate "/usr/lib/libSystem.B.dylib"
  1556  
  1557  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1558  
  1559  func Umask(newmask int) (oldmask int) {
  1560  	r0, _, _ := syscall(abi.FuncPCABI0(libc_umask_trampoline), uintptr(newmask), 0, 0)
  1561  	oldmask = int(r0)
  1562  	return
  1563  }
  1564  
  1565  func libc_umask_trampoline()
  1566  
  1567  //go:cgo_import_dynamic libc_umask umask "/usr/lib/libSystem.B.dylib"
  1568  
  1569  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1570  
  1571  func Undelete(path string) (err error) {
  1572  	var _p0 *byte
  1573  	_p0, err = BytePtrFromString(path)
  1574  	if err != nil {
  1575  		return
  1576  	}
  1577  	_, _, e1 := syscall(abi.FuncPCABI0(libc_undelete_trampoline), uintptr(unsafe.Pointer(_p0)), 0, 0)
  1578  	if e1 != 0 {
  1579  		err = errnoErr(e1)
  1580  	}
  1581  	return
  1582  }
  1583  
  1584  func libc_undelete_trampoline()
  1585  
  1586  //go:cgo_import_dynamic libc_undelete undelete "/usr/lib/libSystem.B.dylib"
  1587  
  1588  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1589  
  1590  func Unlink(path string) (err error) {
  1591  	var _p0 *byte
  1592  	_p0, err = BytePtrFromString(path)
  1593  	if err != nil {
  1594  		return
  1595  	}
  1596  	_, _, e1 := syscall(abi.FuncPCABI0(libc_unlink_trampoline), uintptr(unsafe.Pointer(_p0)), 0, 0)
  1597  	if e1 != 0 {
  1598  		err = errnoErr(e1)
  1599  	}
  1600  	return
  1601  }
  1602  
  1603  func libc_unlink_trampoline()
  1604  
  1605  //go:cgo_import_dynamic libc_unlink unlink "/usr/lib/libSystem.B.dylib"
  1606  
  1607  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1608  
  1609  func Unmount(path string, flags int) (err error) {
  1610  	var _p0 *byte
  1611  	_p0, err = BytePtrFromString(path)
  1612  	if err != nil {
  1613  		return
  1614  	}
  1615  	_, _, e1 := syscall(abi.FuncPCABI0(libc_unmount_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(flags), 0)
  1616  	if e1 != 0 {
  1617  		err = errnoErr(e1)
  1618  	}
  1619  	return
  1620  }
  1621  
  1622  func libc_unmount_trampoline()
  1623  
  1624  //go:cgo_import_dynamic libc_unmount unmount "/usr/lib/libSystem.B.dylib"
  1625  
  1626  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1627  
  1628  func write(fd int, p []byte) (n int, err error) {
  1629  	var _p0 unsafe.Pointer
  1630  	if len(p) > 0 {
  1631  		_p0 = unsafe.Pointer(&p[0])
  1632  	} else {
  1633  		_p0 = unsafe.Pointer(&_zero)
  1634  	}
  1635  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_write_trampoline), uintptr(fd), uintptr(_p0), uintptr(len(p)))
  1636  	n = int(r0)
  1637  	if e1 != 0 {
  1638  		err = errnoErr(e1)
  1639  	}
  1640  	return
  1641  }
  1642  
  1643  func libc_write_trampoline()
  1644  
  1645  //go:cgo_import_dynamic libc_write write "/usr/lib/libSystem.B.dylib"
  1646  
  1647  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1648  
  1649  func writev(fd int, iovecs []Iovec) (cnt uintptr, err error) {
  1650  	var _p0 unsafe.Pointer
  1651  	if len(iovecs) > 0 {
  1652  		_p0 = unsafe.Pointer(&iovecs[0])
  1653  	} else {
  1654  		_p0 = unsafe.Pointer(&_zero)
  1655  	}
  1656  	r0, _, e1 := syscallX(abi.FuncPCABI0(libc_writev_trampoline), uintptr(fd), uintptr(_p0), uintptr(len(iovecs)))
  1657  	cnt = uintptr(r0)
  1658  	if e1 != 0 {
  1659  		err = errnoErr(e1)
  1660  	}
  1661  	return
  1662  }
  1663  
  1664  func libc_writev_trampoline()
  1665  
  1666  //go:cgo_import_dynamic libc_writev writev "/usr/lib/libSystem.B.dylib"
  1667  
  1668  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1669  
  1670  func mmap(addr uintptr, length uintptr, prot int, flag int, fd int, pos int64) (ret uintptr, err error) {
  1671  	r0, _, e1 := syscall6X(abi.FuncPCABI0(libc_mmap_trampoline), uintptr(addr), uintptr(length), uintptr(prot), uintptr(flag), uintptr(fd), uintptr(pos))
  1672  	ret = uintptr(r0)
  1673  	if e1 != 0 {
  1674  		err = errnoErr(e1)
  1675  	}
  1676  	return
  1677  }
  1678  
  1679  func libc_mmap_trampoline()
  1680  
  1681  //go:cgo_import_dynamic libc_mmap mmap "/usr/lib/libSystem.B.dylib"
  1682  
  1683  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1684  
  1685  func munmap(addr uintptr, length uintptr) (err error) {
  1686  	_, _, e1 := syscall(abi.FuncPCABI0(libc_munmap_trampoline), uintptr(addr), uintptr(length), 0)
  1687  	if e1 != 0 {
  1688  		err = errnoErr(e1)
  1689  	}
  1690  	return
  1691  }
  1692  
  1693  func libc_munmap_trampoline()
  1694  
  1695  //go:cgo_import_dynamic libc_munmap munmap "/usr/lib/libSystem.B.dylib"
  1696  
  1697  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1698  
  1699  func fork() (pid int, err error) {
  1700  	r0, _, e1 := rawSyscall(abi.FuncPCABI0(libc_fork_trampoline), 0, 0, 0)
  1701  	pid = int(r0)
  1702  	if e1 != 0 {
  1703  		err = errnoErr(e1)
  1704  	}
  1705  	return
  1706  }
  1707  
  1708  func libc_fork_trampoline()
  1709  
  1710  //go:cgo_import_dynamic libc_fork fork "/usr/lib/libSystem.B.dylib"
  1711  
  1712  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1713  
  1714  func ioctl(fd int, req int, arg int) (err error) {
  1715  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_ioctl_trampoline), uintptr(fd), uintptr(req), uintptr(arg))
  1716  	if e1 != 0 {
  1717  		err = errnoErr(e1)
  1718  	}
  1719  	return
  1720  }
  1721  
  1722  func libc_ioctl_trampoline()
  1723  
  1724  //go:cgo_import_dynamic libc_ioctl ioctl "/usr/lib/libSystem.B.dylib"
  1725  
  1726  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1727  
  1728  func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) {
  1729  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_ioctl_trampoline), uintptr(fd), uintptr(req), uintptr(arg))
  1730  	if e1 != 0 {
  1731  		err = errnoErr(e1)
  1732  	}
  1733  	return
  1734  }
  1735  
  1736  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1737  
  1738  func execve(path *byte, argv **byte, envp **byte) (err error) {
  1739  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_execve_trampoline), uintptr(unsafe.Pointer(path)), uintptr(unsafe.Pointer(argv)), uintptr(unsafe.Pointer(envp)))
  1740  	if e1 != 0 {
  1741  		err = errnoErr(e1)
  1742  	}
  1743  	return
  1744  }
  1745  
  1746  func libc_execve_trampoline()
  1747  
  1748  //go:cgo_import_dynamic libc_execve execve "/usr/lib/libSystem.B.dylib"
  1749  
  1750  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1751  
  1752  func exit(res int) (err error) {
  1753  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_exit_trampoline), uintptr(res), 0, 0)
  1754  	if e1 != 0 {
  1755  		err = errnoErr(e1)
  1756  	}
  1757  	return
  1758  }
  1759  
  1760  func libc_exit_trampoline()
  1761  
  1762  //go:cgo_import_dynamic libc_exit exit "/usr/lib/libSystem.B.dylib"
  1763  
  1764  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1765  
  1766  func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) {
  1767  	var _p0 unsafe.Pointer
  1768  	if len(mib) > 0 {
  1769  		_p0 = unsafe.Pointer(&mib[0])
  1770  	} else {
  1771  		_p0 = unsafe.Pointer(&_zero)
  1772  	}
  1773  	_, _, e1 := syscall6(abi.FuncPCABI0(libc_sysctl_trampoline), uintptr(_p0), uintptr(len(mib)), uintptr(unsafe.Pointer(old)), uintptr(unsafe.Pointer(oldlen)), uintptr(unsafe.Pointer(new)), uintptr(newlen))
  1774  	if e1 != 0 {
  1775  		err = errnoErr(e1)
  1776  	}
  1777  	return
  1778  }
  1779  
  1780  func libc_sysctl_trampoline()
  1781  
  1782  //go:cgo_import_dynamic libc_sysctl sysctl "/usr/lib/libSystem.B.dylib"
  1783  
  1784  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1785  
  1786  func fcntlPtr(fd int, cmd int, arg unsafe.Pointer) (val int, err error) {
  1787  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_fcntl_trampoline), uintptr(fd), uintptr(cmd), uintptr(arg))
  1788  	val = int(r0)
  1789  	if e1 != 0 {
  1790  		err = errnoErr(e1)
  1791  	}
  1792  	return
  1793  }
  1794  
  1795  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1796  
  1797  func unlinkat(fd int, path string, flags int) (err error) {
  1798  	var _p0 *byte
  1799  	_p0, err = BytePtrFromString(path)
  1800  	if err != nil {
  1801  		return
  1802  	}
  1803  	_, _, e1 := syscall(abi.FuncPCABI0(libc_unlinkat_trampoline), uintptr(fd), uintptr(unsafe.Pointer(_p0)), uintptr(flags))
  1804  	if e1 != 0 {
  1805  		err = errnoErr(e1)
  1806  	}
  1807  	return
  1808  }
  1809  
  1810  func libc_unlinkat_trampoline()
  1811  
  1812  //go:cgo_import_dynamic libc_unlinkat unlinkat "/usr/lib/libSystem.B.dylib"
  1813  
  1814  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1815  
  1816  func openat(fd int, path string, flags int, perm uint32) (fdret int, err error) {
  1817  	var _p0 *byte
  1818  	_p0, err = BytePtrFromString(path)
  1819  	if err != nil {
  1820  		return
  1821  	}
  1822  	r0, _, e1 := syscall6(abi.FuncPCABI0(libc_openat_trampoline), uintptr(fd), uintptr(unsafe.Pointer(_p0)), uintptr(flags), uintptr(perm), 0, 0)
  1823  	fdret = int(r0)
  1824  	if e1 != 0 {
  1825  		err = errnoErr(e1)
  1826  	}
  1827  	return
  1828  }
  1829  
  1830  func libc_openat_trampoline()
  1831  
  1832  //go:cgo_import_dynamic libc_openat openat "/usr/lib/libSystem.B.dylib"
  1833  
  1834  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1835  
  1836  func getcwd(buf []byte) (n int, err error) {
  1837  	var _p0 unsafe.Pointer
  1838  	if len(buf) > 0 {
  1839  		_p0 = unsafe.Pointer(&buf[0])
  1840  	} else {
  1841  		_p0 = unsafe.Pointer(&_zero)
  1842  	}
  1843  	r0, _, e1 := syscall(abi.FuncPCABI0(libc_getcwd_trampoline), uintptr(_p0), uintptr(len(buf)), 0)
  1844  	n = int(r0)
  1845  	if e1 != 0 {
  1846  		err = errnoErr(e1)
  1847  	}
  1848  	return
  1849  }
  1850  
  1851  func libc_getcwd_trampoline()
  1852  
  1853  //go:cgo_import_dynamic libc_getcwd getcwd "/usr/lib/libSystem.B.dylib"
  1854  
  1855  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1856  
  1857  func Fstat(fd int, stat *Stat_t) (err error) {
  1858  	_, _, e1 := syscall(abi.FuncPCABI0(libc_fstat64_trampoline), uintptr(fd), uintptr(unsafe.Pointer(stat)), 0)
  1859  	if e1 != 0 {
  1860  		err = errnoErr(e1)
  1861  	}
  1862  	return
  1863  }
  1864  
  1865  func libc_fstat64_trampoline()
  1866  
  1867  //go:cgo_import_dynamic libc_fstat64 fstat64 "/usr/lib/libSystem.B.dylib"
  1868  
  1869  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1870  
  1871  func Fstatfs(fd int, stat *Statfs_t) (err error) {
  1872  	_, _, e1 := syscall(abi.FuncPCABI0(libc_fstatfs64_trampoline), uintptr(fd), uintptr(unsafe.Pointer(stat)), 0)
  1873  	if e1 != 0 {
  1874  		err = errnoErr(e1)
  1875  	}
  1876  	return
  1877  }
  1878  
  1879  func libc_fstatfs64_trampoline()
  1880  
  1881  //go:cgo_import_dynamic libc_fstatfs64 fstatfs64 "/usr/lib/libSystem.B.dylib"
  1882  
  1883  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1884  
  1885  func Gettimeofday(tp *Timeval) (err error) {
  1886  	_, _, e1 := rawSyscall(abi.FuncPCABI0(libc_gettimeofday_trampoline), uintptr(unsafe.Pointer(tp)), 0, 0)
  1887  	if e1 != 0 {
  1888  		err = errnoErr(e1)
  1889  	}
  1890  	return
  1891  }
  1892  
  1893  func libc_gettimeofday_trampoline()
  1894  
  1895  //go:cgo_import_dynamic libc_gettimeofday gettimeofday "/usr/lib/libSystem.B.dylib"
  1896  
  1897  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1898  
  1899  func Lstat(path string, stat *Stat_t) (err error) {
  1900  	var _p0 *byte
  1901  	_p0, err = BytePtrFromString(path)
  1902  	if err != nil {
  1903  		return
  1904  	}
  1905  	_, _, e1 := syscall(abi.FuncPCABI0(libc_lstat64_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), 0)
  1906  	if e1 != 0 {
  1907  		err = errnoErr(e1)
  1908  	}
  1909  	return
  1910  }
  1911  
  1912  func libc_lstat64_trampoline()
  1913  
  1914  //go:cgo_import_dynamic libc_lstat64 lstat64 "/usr/lib/libSystem.B.dylib"
  1915  
  1916  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1917  
  1918  func Stat(path string, stat *Stat_t) (err error) {
  1919  	var _p0 *byte
  1920  	_p0, err = BytePtrFromString(path)
  1921  	if err != nil {
  1922  		return
  1923  	}
  1924  	_, _, e1 := syscall(abi.FuncPCABI0(libc_stat64_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), 0)
  1925  	if e1 != 0 {
  1926  		err = errnoErr(e1)
  1927  	}
  1928  	return
  1929  }
  1930  
  1931  func libc_stat64_trampoline()
  1932  
  1933  //go:cgo_import_dynamic libc_stat64 stat64 "/usr/lib/libSystem.B.dylib"
  1934  
  1935  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1936  
  1937  func Statfs(path string, stat *Statfs_t) (err error) {
  1938  	var _p0 *byte
  1939  	_p0, err = BytePtrFromString(path)
  1940  	if err != nil {
  1941  		return
  1942  	}
  1943  	_, _, e1 := syscall(abi.FuncPCABI0(libc_statfs64_trampoline), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), 0)
  1944  	if e1 != 0 {
  1945  		err = errnoErr(e1)
  1946  	}
  1947  	return
  1948  }
  1949  
  1950  func libc_statfs64_trampoline()
  1951  
  1952  //go:cgo_import_dynamic libc_statfs64 statfs64 "/usr/lib/libSystem.B.dylib"
  1953  
  1954  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1955  
  1956  func fstatat(fd int, path string, stat *Stat_t, flags int) (err error) {
  1957  	var _p0 *byte
  1958  	_p0, err = BytePtrFromString(path)
  1959  	if err != nil {
  1960  		return
  1961  	}
  1962  	_, _, e1 := syscall6(abi.FuncPCABI0(libc_fstatat64_trampoline), uintptr(fd), uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(stat)), uintptr(flags), 0, 0)
  1963  	if e1 != 0 {
  1964  		err = errnoErr(e1)
  1965  	}
  1966  	return
  1967  }
  1968  
  1969  func libc_fstatat64_trampoline()
  1970  
  1971  //go:cgo_import_dynamic libc_fstatat64 fstatat64 "/usr/lib/libSystem.B.dylib"
  1972  
  1973  // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
  1974  
  1975  //go:nosplit
  1976  func ptrace1(request int, pid int, addr uintptr, data uintptr) (err error) {
  1977  	_, _, e1 := syscall6(abi.FuncPCABI0(libc_ptrace_trampoline), uintptr(request), uintptr(pid), uintptr(addr), uintptr(data), 0, 0)
  1978  	if e1 != 0 {
  1979  		err = errnoErr(e1)
  1980  	}
  1981  	return
  1982  }
  1983  
  1984  func libc_ptrace_trampoline()
  1985  
  1986  //go:cgo_import_dynamic libc_ptrace ptrace "/usr/lib/libSystem.B.dylib"
  1987  

View as plain text