Source file src/runtime/defs1_netbsd_amd64.go

     1  // created by cgo -cdefs and then converted to Go
     2  // cgo -cdefs defs_netbsd.go defs_netbsd_amd64.go
     3  
     4  package runtime
     5  
     6  const (
     7  	_EINTR  = 0x4
     8  	_EFAULT = 0xe
     9  	_EAGAIN = 0x23
    10  
    11  	_O_NONBLOCK = 0x4
    12  	_O_CLOEXEC  = 0x400000
    13  
    14  	_PROT_NONE  = 0x0
    15  	_PROT_READ  = 0x1
    16  	_PROT_WRITE = 0x2
    17  	_PROT_EXEC  = 0x4
    18  
    19  	_MAP_ANON    = 0x1000
    20  	_MAP_PRIVATE = 0x2
    21  	_MAP_FIXED   = 0x10
    22  
    23  	_MADV_FREE = 0x6
    24  
    25  	_SA_SIGINFO = 0x40
    26  	_SA_RESTART = 0x2
    27  	_SA_ONSTACK = 0x1
    28  
    29  	_SIGHUP    = 0x1
    30  	_SIGINT    = 0x2
    31  	_SIGQUIT   = 0x3
    32  	_SIGILL    = 0x4
    33  	_SIGTRAP   = 0x5
    34  	_SIGABRT   = 0x6
    35  	_SIGEMT    = 0x7
    36  	_SIGFPE    = 0x8
    37  	_SIGKILL   = 0x9
    38  	_SIGBUS    = 0xa
    39  	_SIGSEGV   = 0xb
    40  	_SIGSYS    = 0xc
    41  	_SIGPIPE   = 0xd
    42  	_SIGALRM   = 0xe
    43  	_SIGTERM   = 0xf
    44  	_SIGURG    = 0x10
    45  	_SIGSTOP   = 0x11
    46  	_SIGTSTP   = 0x12
    47  	_SIGCONT   = 0x13
    48  	_SIGCHLD   = 0x14
    49  	_SIGTTIN   = 0x15
    50  	_SIGTTOU   = 0x16
    51  	_SIGIO     = 0x17
    52  	_SIGXCPU   = 0x18
    53  	_SIGXFSZ   = 0x19
    54  	_SIGVTALRM = 0x1a
    55  	_SIGPROF   = 0x1b
    56  	_SIGWINCH  = 0x1c
    57  	_SIGINFO   = 0x1d
    58  	_SIGUSR1   = 0x1e
    59  	_SIGUSR2   = 0x1f
    60  
    61  	_FPE_INTDIV = 0x1
    62  	_FPE_INTOVF = 0x2
    63  	_FPE_FLTDIV = 0x3
    64  	_FPE_FLTOVF = 0x4
    65  	_FPE_FLTUND = 0x5
    66  	_FPE_FLTRES = 0x6
    67  	_FPE_FLTINV = 0x7
    68  	_FPE_FLTSUB = 0x8
    69  
    70  	_BUS_ADRALN = 0x1
    71  	_BUS_ADRERR = 0x2
    72  	_BUS_OBJERR = 0x3
    73  
    74  	_SEGV_MAPERR = 0x1
    75  	_SEGV_ACCERR = 0x2
    76  
    77  	_ITIMER_REAL    = 0x0
    78  	_ITIMER_VIRTUAL = 0x1
    79  	_ITIMER_PROF    = 0x2
    80  
    81  	_EV_ADD       = 0x1
    82  	_EV_DELETE    = 0x2
    83  	_EV_CLEAR     = 0x20
    84  	_EV_RECEIPT   = 0
    85  	_EV_ERROR     = 0x4000
    86  	_EV_EOF       = 0x8000
    87  	_EVFILT_READ  = 0x0
    88  	_EVFILT_WRITE = 0x1
    89  )
    90  
    91  type sigset struct {
    92  	__bits [4]uint32
    93  }
    94  
    95  type siginfo struct {
    96  	_signo  int32
    97  	_code   int32
    98  	_errno  int32
    99  	_pad    int32
   100  	_reason [24]byte
   101  }
   102  
   103  type stackt struct {
   104  	ss_sp     uintptr
   105  	ss_size   uintptr
   106  	ss_flags  int32
   107  	pad_cgo_0 [4]byte
   108  }
   109  
   110  type timespec struct {
   111  	tv_sec  int64
   112  	tv_nsec int64
   113  }
   114  
   115  //go:nosplit
   116  func (ts *timespec) setNsec(ns int64) {
   117  	ts.tv_sec = ns / 1e9
   118  	ts.tv_nsec = ns % 1e9
   119  }
   120  
   121  type timeval struct {
   122  	tv_sec    int64
   123  	tv_usec   int32
   124  	pad_cgo_0 [4]byte
   125  }
   126  
   127  func (tv *timeval) set_usec(x int32) {
   128  	tv.tv_usec = x
   129  }
   130  
   131  type itimerval struct {
   132  	it_interval timeval
   133  	it_value    timeval
   134  }
   135  
   136  type mcontextt struct {
   137  	__gregs     [26]uint64
   138  	_mc_tlsbase uint64
   139  	__fpregs    [512]int8
   140  }
   141  
   142  type ucontextt struct {
   143  	uc_flags    uint32
   144  	pad_cgo_0   [4]byte
   145  	uc_link     *ucontextt
   146  	uc_sigmask  sigset
   147  	uc_stack    stackt
   148  	uc_mcontext mcontextt
   149  }
   150  
   151  type keventt struct {
   152  	ident     uint64
   153  	filter    uint32
   154  	flags     uint32
   155  	fflags    uint32
   156  	pad_cgo_0 [4]byte
   157  	data      int64
   158  	udata     *byte
   159  }
   160  
   161  // created by cgo -cdefs and then converted to Go
   162  // cgo -cdefs defs_netbsd.go defs_netbsd_amd64.go
   163  
   164  const (
   165  	_REG_RDI    = 0x0
   166  	_REG_RSI    = 0x1
   167  	_REG_RDX    = 0x2
   168  	_REG_RCX    = 0x3
   169  	_REG_R8     = 0x4
   170  	_REG_R9     = 0x5
   171  	_REG_R10    = 0x6
   172  	_REG_R11    = 0x7
   173  	_REG_R12    = 0x8
   174  	_REG_R13    = 0x9
   175  	_REG_R14    = 0xa
   176  	_REG_R15    = 0xb
   177  	_REG_RBP    = 0xc
   178  	_REG_RBX    = 0xd
   179  	_REG_RAX    = 0xe
   180  	_REG_GS     = 0xf
   181  	_REG_FS     = 0x10
   182  	_REG_ES     = 0x11
   183  	_REG_DS     = 0x12
   184  	_REG_TRAPNO = 0x13
   185  	_REG_ERR    = 0x14
   186  	_REG_RIP    = 0x15
   187  	_REG_CS     = 0x16
   188  	_REG_RFLAGS = 0x17
   189  	_REG_RSP    = 0x18
   190  	_REG_SS     = 0x19
   191  )
   192  

View as plain text