Black Lives Matter. Support the Equal Justice Initiative.

Source file src/runtime/defs_dragonfly_amd64.go

Documentation: runtime

     1  // created by cgo -cdefs and then converted to Go
     2  // cgo -cdefs defs_dragonfly.go
     3  
     4  package runtime
     5  
     6  import "unsafe"
     7  
     8  const (
     9  	_EINTR  = 0x4
    10  	_EFAULT = 0xe
    11  	_EBUSY  = 0x10
    12  	_EAGAIN = 0x23
    13  	_ENOSYS = 0x4e
    14  
    15  	_O_NONBLOCK = 0x4
    16  	_O_CLOEXEC  = 0x20000
    17  
    18  	_PROT_NONE  = 0x0
    19  	_PROT_READ  = 0x1
    20  	_PROT_WRITE = 0x2
    21  	_PROT_EXEC  = 0x4
    22  
    23  	_MAP_ANON    = 0x1000
    24  	_MAP_PRIVATE = 0x2
    25  	_MAP_FIXED   = 0x10
    26  
    27  	_MADV_FREE = 0x5
    28  
    29  	_SA_SIGINFO = 0x40
    30  	_SA_RESTART = 0x2
    31  	_SA_ONSTACK = 0x1
    32  
    33  	_SIGHUP    = 0x1
    34  	_SIGINT    = 0x2
    35  	_SIGQUIT   = 0x3
    36  	_SIGILL    = 0x4
    37  	_SIGTRAP   = 0x5
    38  	_SIGABRT   = 0x6
    39  	_SIGEMT    = 0x7
    40  	_SIGFPE    = 0x8
    41  	_SIGKILL   = 0x9
    42  	_SIGBUS    = 0xa
    43  	_SIGSEGV   = 0xb
    44  	_SIGSYS    = 0xc
    45  	_SIGPIPE   = 0xd
    46  	_SIGALRM   = 0xe
    47  	_SIGTERM   = 0xf
    48  	_SIGURG    = 0x10
    49  	_SIGSTOP   = 0x11
    50  	_SIGTSTP   = 0x12
    51  	_SIGCONT   = 0x13
    52  	_SIGCHLD   = 0x14
    53  	_SIGTTIN   = 0x15
    54  	_SIGTTOU   = 0x16
    55  	_SIGIO     = 0x17
    56  	_SIGXCPU   = 0x18
    57  	_SIGXFSZ   = 0x19
    58  	_SIGVTALRM = 0x1a
    59  	_SIGPROF   = 0x1b
    60  	_SIGWINCH  = 0x1c
    61  	_SIGINFO   = 0x1d
    62  	_SIGUSR1   = 0x1e
    63  	_SIGUSR2   = 0x1f
    64  
    65  	_FPE_INTDIV = 0x2
    66  	_FPE_INTOVF = 0x1
    67  	_FPE_FLTDIV = 0x3
    68  	_FPE_FLTOVF = 0x4
    69  	_FPE_FLTUND = 0x5
    70  	_FPE_FLTRES = 0x6
    71  	_FPE_FLTINV = 0x7
    72  	_FPE_FLTSUB = 0x8
    73  
    74  	_BUS_ADRALN = 0x1
    75  	_BUS_ADRERR = 0x2
    76  	_BUS_OBJERR = 0x3
    77  
    78  	_SEGV_MAPERR = 0x1
    79  	_SEGV_ACCERR = 0x2
    80  
    81  	_ITIMER_REAL    = 0x0
    82  	_ITIMER_VIRTUAL = 0x1
    83  	_ITIMER_PROF    = 0x2
    84  
    85  	_EV_ADD       = 0x1
    86  	_EV_DELETE    = 0x2
    87  	_EV_CLEAR     = 0x20
    88  	_EV_ERROR     = 0x4000
    89  	_EV_EOF       = 0x8000
    90  	_EVFILT_READ  = -0x1
    91  	_EVFILT_WRITE = -0x2
    92  )
    93  
    94  type rtprio struct {
    95  	_type uint16
    96  	prio  uint16
    97  }
    98  
    99  type lwpparams struct {
   100  	start_func uintptr
   101  	arg        unsafe.Pointer
   102  	stack      uintptr
   103  	tid1       unsafe.Pointer // *int32
   104  	tid2       unsafe.Pointer // *int32
   105  }
   106  
   107  type sigset struct {
   108  	__bits [4]uint32
   109  }
   110  
   111  type stackt struct {
   112  	ss_sp     uintptr
   113  	ss_size   uintptr
   114  	ss_flags  int32
   115  	pad_cgo_0 [4]byte
   116  }
   117  
   118  type siginfo struct {
   119  	si_signo  int32
   120  	si_errno  int32
   121  	si_code   int32
   122  	si_pid    int32
   123  	si_uid    uint32
   124  	si_status int32
   125  	si_addr   uint64
   126  	si_value  [8]byte
   127  	si_band   int64
   128  	__spare__ [7]int32
   129  	pad_cgo_0 [4]byte
   130  }
   131  
   132  type mcontext struct {
   133  	mc_onstack  uint64
   134  	mc_rdi      uint64
   135  	mc_rsi      uint64
   136  	mc_rdx      uint64
   137  	mc_rcx      uint64
   138  	mc_r8       uint64
   139  	mc_r9       uint64
   140  	mc_rax      uint64
   141  	mc_rbx      uint64
   142  	mc_rbp      uint64
   143  	mc_r10      uint64
   144  	mc_r11      uint64
   145  	mc_r12      uint64
   146  	mc_r13      uint64
   147  	mc_r14      uint64
   148  	mc_r15      uint64
   149  	mc_xflags   uint64
   150  	mc_trapno   uint64
   151  	mc_addr     uint64
   152  	mc_flags    uint64
   153  	mc_err      uint64
   154  	mc_rip      uint64
   155  	mc_cs       uint64
   156  	mc_rflags   uint64
   157  	mc_rsp      uint64
   158  	mc_ss       uint64
   159  	mc_len      uint32
   160  	mc_fpformat uint32
   161  	mc_ownedfp  uint32
   162  	mc_reserved uint32
   163  	mc_unused   [8]uint32
   164  	mc_fpregs   [256]int32
   165  }
   166  
   167  type ucontext struct {
   168  	uc_sigmask  sigset
   169  	pad_cgo_0   [48]byte
   170  	uc_mcontext mcontext
   171  	uc_link     *ucontext
   172  	uc_stack    stackt
   173  	__spare__   [8]int32
   174  }
   175  
   176  type timespec struct {
   177  	tv_sec  int64
   178  	tv_nsec int64
   179  }
   180  
   181  //go:nosplit
   182  func (ts *timespec) setNsec(ns int64) {
   183  	ts.tv_sec = ns / 1e9
   184  	ts.tv_nsec = ns % 1e9
   185  }
   186  
   187  type timeval struct {
   188  	tv_sec  int64
   189  	tv_usec int64
   190  }
   191  
   192  func (tv *timeval) set_usec(x int32) {
   193  	tv.tv_usec = int64(x)
   194  }
   195  
   196  type itimerval struct {
   197  	it_interval timeval
   198  	it_value    timeval
   199  }
   200  
   201  type keventt struct {
   202  	ident  uint64
   203  	filter int16
   204  	flags  uint16
   205  	fflags uint32
   206  	data   int64
   207  	udata  *byte
   208  }
   209  

View as plain text