Home | History | Annotate | Download | only in runtime
      1 // created by cgo -cdefs and then converted to Go
      2 // cgo -cdefs defs_solaris.go defs_solaris_amd64.go
      3 
      4 package runtime
      5 
      6 const (
      7 	_EINTR       = 0x4
      8 	_EBADF       = 0x9
      9 	_EFAULT      = 0xe
     10 	_EAGAIN      = 0xb
     11 	_ETIMEDOUT   = 0x91
     12 	_EWOULDBLOCK = 0xb
     13 	_EINPROGRESS = 0x96
     14 
     15 	_PROT_NONE  = 0x0
     16 	_PROT_READ  = 0x1
     17 	_PROT_WRITE = 0x2
     18 	_PROT_EXEC  = 0x4
     19 
     20 	_MAP_ANON    = 0x100
     21 	_MAP_PRIVATE = 0x2
     22 	_MAP_FIXED   = 0x10
     23 
     24 	_MADV_FREE = 0x5
     25 
     26 	_SA_SIGINFO = 0x8
     27 	_SA_RESTART = 0x4
     28 	_SA_ONSTACK = 0x1
     29 
     30 	_SIGHUP    = 0x1
     31 	_SIGINT    = 0x2
     32 	_SIGQUIT   = 0x3
     33 	_SIGILL    = 0x4
     34 	_SIGTRAP   = 0x5
     35 	_SIGABRT   = 0x6
     36 	_SIGEMT    = 0x7
     37 	_SIGFPE    = 0x8
     38 	_SIGKILL   = 0x9
     39 	_SIGBUS    = 0xa
     40 	_SIGSEGV   = 0xb
     41 	_SIGSYS    = 0xc
     42 	_SIGPIPE   = 0xd
     43 	_SIGALRM   = 0xe
     44 	_SIGTERM   = 0xf
     45 	_SIGURG    = 0x15
     46 	_SIGSTOP   = 0x17
     47 	_SIGTSTP   = 0x18
     48 	_SIGCONT   = 0x19
     49 	_SIGCHLD   = 0x12
     50 	_SIGTTIN   = 0x1a
     51 	_SIGTTOU   = 0x1b
     52 	_SIGIO     = 0x16
     53 	_SIGXCPU   = 0x1e
     54 	_SIGXFSZ   = 0x1f
     55 	_SIGVTALRM = 0x1c
     56 	_SIGPROF   = 0x1d
     57 	_SIGWINCH  = 0x14
     58 	_SIGUSR1   = 0x10
     59 	_SIGUSR2   = 0x11
     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 	__SC_PAGESIZE         = 0xb
     82 	__SC_NPROCESSORS_ONLN = 0xf
     83 
     84 	_PTHREAD_CREATE_DETACHED = 0x40
     85 
     86 	_FORK_NOSIGCHLD = 0x1
     87 	_FORK_WAITPID   = 0x2
     88 
     89 	_MAXHOSTNAMELEN = 0x100
     90 
     91 	_O_NONBLOCK = 0x80
     92 	_FD_CLOEXEC = 0x1
     93 	_F_GETFL    = 0x3
     94 	_F_SETFL    = 0x4
     95 	_F_SETFD    = 0x2
     96 
     97 	_POLLIN  = 0x1
     98 	_POLLOUT = 0x4
     99 	_POLLHUP = 0x10
    100 	_POLLERR = 0x8
    101 
    102 	_PORT_SOURCE_FD = 0x4
    103 )
    104 
    105 type semt struct {
    106 	sem_count uint32
    107 	sem_type  uint16
    108 	sem_magic uint16
    109 	sem_pad1  [3]uint64
    110 	sem_pad2  [2]uint64
    111 }
    112 
    113 type sigset struct {
    114 	__sigbits [4]uint32
    115 }
    116 
    117 type stackt struct {
    118 	ss_sp     *byte
    119 	ss_size   uintptr
    120 	ss_flags  int32
    121 	pad_cgo_0 [4]byte
    122 }
    123 
    124 type siginfo struct {
    125 	si_signo int32
    126 	si_code  int32
    127 	si_errno int32
    128 	si_pad   int32
    129 	__data   [240]byte
    130 }
    131 
    132 type sigactiont struct {
    133 	sa_flags  int32
    134 	pad_cgo_0 [4]byte
    135 	_funcptr  [8]byte
    136 	sa_mask   sigset
    137 }
    138 
    139 type fpregset struct {
    140 	fp_reg_set [528]byte
    141 }
    142 
    143 type mcontext struct {
    144 	gregs  [28]int64
    145 	fpregs fpregset
    146 }
    147 
    148 type ucontext struct {
    149 	uc_flags    uint64
    150 	uc_link     *ucontext
    151 	uc_sigmask  sigset
    152 	uc_stack    stackt
    153 	pad_cgo_0   [8]byte
    154 	uc_mcontext mcontext
    155 	uc_filler   [5]int64
    156 	pad_cgo_1   [8]byte
    157 }
    158 
    159 type timespec struct {
    160 	tv_sec  int64
    161 	tv_nsec int64
    162 }
    163 
    164 type timeval struct {
    165 	tv_sec  int64
    166 	tv_usec int64
    167 }
    168 
    169 func (tv *timeval) set_usec(x int32) {
    170 	tv.tv_usec = int64(x)
    171 }
    172 
    173 type itimerval struct {
    174 	it_interval timeval
    175 	it_value    timeval
    176 }
    177 
    178 type portevent struct {
    179 	portev_events int32
    180 	portev_source uint16
    181 	portev_pad    uint16
    182 	portev_object uint64
    183 	portev_user   *byte
    184 }
    185 
    186 type pthread uint32
    187 type pthreadattr struct {
    188 	__pthread_attrp *byte
    189 }
    190 
    191 type stat struct {
    192 	st_dev     uint64
    193 	st_ino     uint64
    194 	st_mode    uint32
    195 	st_nlink   uint32
    196 	st_uid     uint32
    197 	st_gid     uint32
    198 	st_rdev    uint64
    199 	st_size    int64
    200 	st_atim    timespec
    201 	st_mtim    timespec
    202 	st_ctim    timespec
    203 	st_blksize int32
    204 	pad_cgo_0  [4]byte
    205 	st_blocks  int64
    206 	st_fstype  [16]int8
    207 }
    208 
    209 // created by cgo -cdefs and then converted to Go
    210 // cgo -cdefs defs_solaris.go defs_solaris_amd64.go
    211 
    212 const (
    213 	_REG_RDI    = 0x8
    214 	_REG_RSI    = 0x9
    215 	_REG_RDX    = 0xc
    216 	_REG_RCX    = 0xd
    217 	_REG_R8     = 0x7
    218 	_REG_R9     = 0x6
    219 	_REG_R10    = 0x5
    220 	_REG_R11    = 0x4
    221 	_REG_R12    = 0x3
    222 	_REG_R13    = 0x2
    223 	_REG_R14    = 0x1
    224 	_REG_R15    = 0x0
    225 	_REG_RBP    = 0xa
    226 	_REG_RBX    = 0xb
    227 	_REG_RAX    = 0xe
    228 	_REG_GS     = 0x17
    229 	_REG_FS     = 0x16
    230 	_REG_ES     = 0x18
    231 	_REG_DS     = 0x19
    232 	_REG_TRAPNO = 0xf
    233 	_REG_ERR    = 0x10
    234 	_REG_RIP    = 0x11
    235 	_REG_CS     = 0x12
    236 	_REG_RFLAGS = 0x13
    237 	_REG_RSP    = 0x14
    238 	_REG_SS     = 0x15
    239 )
    240