signal_freebsd_arm.go 65 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414
  1. // Code generated by 'ccgo signal/gen.c -crt-import-path "" -export-defines "" -export-enums "" -export-externs X -export-fields F -export-structs "" -export-typedefs "" -header -hide _OSSwapInt16,_OSSwapInt32,_OSSwapInt64 -ignore-unsupported-alignment -o signal/signal_freebsd_arm.go -pkgname signal', DO NOT EDIT.
  2. package signal
  3. import (
  4. "math"
  5. "reflect"
  6. "sync/atomic"
  7. "unsafe"
  8. )
  9. var _ = math.Pi
  10. var _ reflect.Kind
  11. var _ atomic.Value
  12. var _ unsafe.Pointer
  13. const (
  14. BUS_ADRALN = 1 // signal.h:315:1:
  15. BUS_ADRERR = 2 // signal.h:316:1:
  16. BUS_OBJERR = 3 // signal.h:317:1:
  17. BUS_OOMERR = 100 // signal.h:318:1:
  18. CLD_CONTINUED = 6 // signal.h:350:1:
  19. CLD_DUMPED = 3 // signal.h:346:1:
  20. CLD_EXITED = 1 // signal.h:343:1:
  21. CLD_KILLED = 2 // signal.h:344:1:
  22. CLD_STOPPED = 5 // signal.h:349:1:
  23. CLD_TRAPPED = 4 // signal.h:348:1:
  24. FPE_FLTDIV = 3 // signal.h:329:1:
  25. FPE_FLTINV = 7 // signal.h:333:1:
  26. FPE_FLTOVF = 4 // signal.h:330:1:
  27. FPE_FLTRES = 6 // signal.h:332:1:
  28. FPE_FLTSUB = 8 // signal.h:334:1:
  29. FPE_FLTUND = 5 // signal.h:331:1:
  30. FPE_INTDIV = 2 // signal.h:328:1:
  31. FPE_INTOVF = 1 // signal.h:327:1:
  32. ILL_BADSTK = 8 // signal.h:312:1:
  33. ILL_COPROC = 7 // signal.h:311:1:
  34. ILL_ILLADR = 3 // signal.h:307:1:
  35. ILL_ILLOPC = 1 // signal.h:305:1:
  36. ILL_ILLOPN = 2 // signal.h:306:1:
  37. ILL_ILLTRP = 4 // signal.h:308:1:
  38. ILL_PRVOPC = 5 // signal.h:309:1:
  39. ILL_PRVREG = 6 // signal.h:310:1:
  40. MINSIGSTKSZ = 4096 // signal.h:432:1:
  41. NSIG = 32 // signal.h:399:1:
  42. POLL_ERR = 4 // signal.h:356:1:
  43. POLL_HUP = 6 // signal.h:358:1:
  44. POLL_IN = 1 // signal.h:353:1:
  45. POLL_MSG = 3 // signal.h:355:1:
  46. POLL_OUT = 2 // signal.h:354:1:
  47. POLL_PRI = 5 // signal.h:357:1:
  48. SA_NOCLDSTOP = 0x0008 // signal.h:386:1:
  49. SA_NOCLDWAIT = 0x0020 // signal.h:394:1:
  50. SA_NODEFER = 0x0010 // signal.h:393:1:
  51. SA_ONSTACK = 0x0001 // signal.h:390:1:
  52. SA_RESETHAND = 0x0004 // signal.h:392:1:
  53. SA_RESTART = 0x0002 // signal.h:391:1:
  54. SA_SIGINFO = 0x0040 // signal.h:395:1:
  55. SEGV_ACCERR = 2 // signal.h:322:1:
  56. SEGV_MAPERR = 1 // signal.h:321:1:
  57. SEGV_PKUERR = 100 // signal.h:324:1:
  58. SIGABRT = 6 // signal.h:81:1:
  59. SIGALRM = 14 // signal.h:99:1:
  60. SIGBUS = 10 // signal.h:91:1:
  61. SIGCHLD = 20 // signal.h:109:1:
  62. SIGCONT = 19 // signal.h:108:1:
  63. SIGEMT = 7 // signal.h:84:1:
  64. SIGEV_KEVENT = 3 // signal.h:222:1:
  65. SIGEV_NONE = 0 // signal.h:218:1:
  66. SIGEV_SIGNAL = 1 // signal.h:219:1:
  67. SIGEV_THREAD = 2 // signal.h:220:1:
  68. SIGEV_THREAD_ID = 4 // signal.h:223:1:
  69. SIGFPE = 8 // signal.h:86:1:
  70. SIGHUP = 1 // signal.h:71:1:
  71. SIGILL = 4 // signal.h:77:1:
  72. SIGINFO = 29 // signal.h:124:1:
  73. SIGINT = 2 // signal.h:73:1:
  74. SIGIO = 23 // signal.h:114:1:
  75. SIGIOT = 6 // signal.h:83:1:
  76. SIGKILL = 9 // signal.h:88:1:
  77. SIGLIBRT = 33 // signal.h:133:1:
  78. SIGLWP = 32 // signal.h:132:1:
  79. SIGPIPE = 13 // signal.h:98:1:
  80. SIGPROF = 27 // signal.h:120:1:
  81. SIGQUIT = 3 // signal.h:75:1:
  82. SIGRTMAX = 126 // signal.h:137:1:
  83. SIGRTMIN = 65 // signal.h:136:1:
  84. SIGSEGV = 11 // signal.h:93:1:
  85. SIGSTKSZ = 36864 // signal.h:433:1:
  86. SIGSTOP = 17 // signal.h:106:1:
  87. SIGSYS = 12 // signal.h:95:1:
  88. SIGTERM = 15 // signal.h:101:1:
  89. SIGTHR = 32 // signal.h:131:1:
  90. SIGTRAP = 5 // signal.h:79:1:
  91. SIGTSTP = 18 // signal.h:107:1:
  92. SIGTTIN = 21 // signal.h:110:1:
  93. SIGTTOU = 22 // signal.h:111:1:
  94. SIGURG = 16 // signal.h:103:1:
  95. SIGUSR1 = 30 // signal.h:127:1:
  96. SIGUSR2 = 31 // signal.h:128:1:
  97. SIGVTALRM = 26 // signal.h:119:1:
  98. SIGWINCH = 28 // signal.h:123:1:
  99. SIGXCPU = 24 // signal.h:117:1:
  100. SIGXFSZ = 25 // signal.h:118:1:
  101. SIG_BLOCK = 1 // signal.h:501:1:
  102. SIG_SETMASK = 3 // signal.h:503:1:
  103. SIG_UNBLOCK = 2 // signal.h:502:1:
  104. SI_ASYNCIO = 0x10004 // signal.h:408:1:
  105. SI_KERNEL = 0x10006 // signal.h:412:1:
  106. SI_LWP = 0x10007 // signal.h:413:1:
  107. SI_MESGQ = 0x10005 // signal.h:410:1:
  108. SI_NOINFO = 0 // signal.h:403:1:
  109. SI_QUEUE = 0x10002 // signal.h:405:1:
  110. SI_TIMER = 0x10003 // signal.h:406:1:
  111. SI_UNDEFINED = 0 // signal.h:416:1:
  112. SI_USER = 0x10001 // signal.h:404:1:
  113. SS_DISABLE = 0x0004 // signal.h:431:1:
  114. SS_ONSTACK = 0x0001 // signal.h:430:1:
  115. SV_INTERRUPT = 2 // signal.h:459:1:
  116. SV_NOCLDSTOP = 8 // signal.h:462:1:
  117. SV_NODEFER = 16 // signal.h:461:1:
  118. SV_ONSTACK = 1 // signal.h:458:1:
  119. SV_RESETHAND = 4 // signal.h:460:1:
  120. SV_SIGINFO = 64 // signal.h:463:1:
  121. TRAP_BRKPT = 1 // signal.h:337:1:
  122. TRAP_CAP = 4 // signal.h:340:1:
  123. TRAP_DTRACE = 3 // signal.h:339:1:
  124. TRAP_TRACE = 2 // signal.h:338:1:
  125. UC_ = 0 // ucontext.h:88:1:
  126. X_FILE_OFFSET_BITS = 64 // <builtin>:25:1:
  127. X_ILP32 = 1 // <predefined>:1:1:
  128. X_MACHINE_MCONTEXT_H_ = 0 // ucontext.h:37:1:
  129. X_MACHINE_SIGNAL_H_ = 0 // signal.h:38:1:
  130. X_MACHINE__LIMITS_H_ = 0 // _limits.h:36:1:
  131. X_MACHINE__TYPES_H_ = 0 // _types.h:42:1:
  132. X_NGREG = 17 // ucontext.h:41:1:
  133. X_Nonnull = 0 // cdefs.h:790:1:
  134. X_Null_unspecified = 0 // cdefs.h:792:1:
  135. X_Nullable = 0 // cdefs.h:791:1:
  136. X_PID_T_DECLARED = 0 // signal.h:61:1:
  137. X_PTHREAD_T_DECLARED = 0 // _pthreadtypes.h:68:1:
  138. X_REG_CPSR = 16 // ucontext.h:61:1:
  139. X_REG_FP = 11 // ucontext.h:63:1:
  140. X_REG_LR = 14 // ucontext.h:65:1:
  141. X_REG_PC = 15 // ucontext.h:66:1:
  142. X_REG_R0 = 0 // ucontext.h:45:1:
  143. X_REG_R1 = 1 // ucontext.h:46:1:
  144. X_REG_R10 = 10 // ucontext.h:55:1:
  145. X_REG_R11 = 11 // ucontext.h:56:1:
  146. X_REG_R12 = 12 // ucontext.h:57:1:
  147. X_REG_R13 = 13 // ucontext.h:58:1:
  148. X_REG_R14 = 14 // ucontext.h:59:1:
  149. X_REG_R15 = 15 // ucontext.h:60:1:
  150. X_REG_R2 = 2 // ucontext.h:47:1:
  151. X_REG_R3 = 3 // ucontext.h:48:1:
  152. X_REG_R4 = 4 // ucontext.h:49:1:
  153. X_REG_R5 = 5 // ucontext.h:50:1:
  154. X_REG_R6 = 6 // ucontext.h:51:1:
  155. X_REG_R7 = 7 // ucontext.h:52:1:
  156. X_REG_R8 = 8 // ucontext.h:53:1:
  157. X_REG_R9 = 9 // ucontext.h:54:1:
  158. X_REG_SP = 13 // ucontext.h:64:1:
  159. X_SIGNAL_H_ = 0 // signal.h:36:1:
  160. X_SIGSET_T_DECLARED = 0 // signal.h:165:1:
  161. X_SIG_MAXSIG = 128 // _sigset.h:47:1:
  162. X_SIG_WORDS = 4 // _sigset.h:46:1:
  163. X_SIZE_T_DECLARED = 0 // signal.h:57:1:
  164. X_SYS_CDEFS_H_ = 0 // cdefs.h:39:1:
  165. X_SYS_SIGNAL_H_ = 0 // signal.h:41:1:
  166. X_SYS__PTHREADTYPES_H_ = 0 // _pthreadtypes.h:39:1:
  167. X_SYS__SIGSET_H_ = 0 // _sigset.h:41:1:
  168. X_SYS__TIMESPEC_H_ = 0 // _timespec.h:37:1:
  169. X_SYS__TYPES_H_ = 0 // _types.h:32:1:
  170. X_SYS__UCONTEXT_H_ = 0 // _ucontext.h:34:1:
  171. X_TIME_T_DECLARED = 0 // _timespec.h:43:1:
  172. X_UID_T_DECLARED = 0 // signal.h:62:1:
  173. Unix = 1 // <predefined>:367:1:
  174. )
  175. type Ptrdiff_t = int32 /* <builtin>:3:26 */
  176. type Size_t = uint32 /* <builtin>:9:23 */
  177. type Wchar_t = uint32 /* <builtin>:15:24 */
  178. type X__builtin_va_list = uintptr /* <builtin>:46:14 */
  179. type X__float128 = float64 /* <builtin>:47:21 */
  180. // -
  181. // SPDX-License-Identifier: BSD-3-Clause
  182. //
  183. // Copyright (c) 1991, 1993
  184. // The Regents of the University of California. All rights reserved.
  185. //
  186. // Redistribution and use in source and binary forms, with or without
  187. // modification, are permitted provided that the following conditions
  188. // are met:
  189. // 1. Redistributions of source code must retain the above copyright
  190. // notice, this list of conditions and the following disclaimer.
  191. // 2. Redistributions in binary form must reproduce the above copyright
  192. // notice, this list of conditions and the following disclaimer in the
  193. // documentation and/or other materials provided with the distribution.
  194. // 3. Neither the name of the University nor the names of its contributors
  195. // may be used to endorse or promote products derived from this software
  196. // without specific prior written permission.
  197. //
  198. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  199. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  200. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  201. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  202. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  203. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  204. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  205. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  206. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  207. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  208. // SUCH DAMAGE.
  209. //
  210. // @(#)signal.h 8.3 (Berkeley) 3/30/94
  211. // $FreeBSD$
  212. // -
  213. // SPDX-License-Identifier: BSD-3-Clause
  214. //
  215. // Copyright (c) 1991, 1993
  216. // The Regents of the University of California. All rights reserved.
  217. //
  218. // This code is derived from software contributed to Berkeley by
  219. // Berkeley Software Design, Inc.
  220. //
  221. // Redistribution and use in source and binary forms, with or without
  222. // modification, are permitted provided that the following conditions
  223. // are met:
  224. // 1. Redistributions of source code must retain the above copyright
  225. // notice, this list of conditions and the following disclaimer.
  226. // 2. Redistributions in binary form must reproduce the above copyright
  227. // notice, this list of conditions and the following disclaimer in the
  228. // documentation and/or other materials provided with the distribution.
  229. // 3. Neither the name of the University nor the names of its contributors
  230. // may be used to endorse or promote products derived from this software
  231. // without specific prior written permission.
  232. //
  233. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  234. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  235. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  236. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  237. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  238. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  239. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  240. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  241. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  242. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  243. // SUCH DAMAGE.
  244. //
  245. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  246. // $FreeBSD$
  247. // Testing against Clang-specific extensions.
  248. // This code has been put in place to help reduce the addition of
  249. // compiler specific defines in FreeBSD code. It helps to aid in
  250. // having a compiler-agnostic source tree.
  251. // Compiler memory barriers, specific to gcc and clang.
  252. // XXX: if __GNUC__ >= 2: not tested everywhere originally, where replaced
  253. // Macro to test if we're using a specific version of gcc or later.
  254. // The __CONCAT macro is used to concatenate parts of symbol names, e.g.
  255. // with "#define OLD(foo) __CONCAT(old,foo)", OLD(foo) produces oldfoo.
  256. // The __CONCAT macro is a bit tricky to use if it must work in non-ANSI
  257. // mode -- there must be no spaces between its arguments, and for nested
  258. // __CONCAT's, all the __CONCAT's must be at the left. __CONCAT can also
  259. // concatenate double-quoted strings produced by the __STRING macro, but
  260. // this only works with ANSI C.
  261. //
  262. // __XSTRING is like __STRING, but it expands any macros in its argument
  263. // first. It is only available with ANSI C.
  264. // Compiler-dependent macros to help declare dead (non-returning) and
  265. // pure (no side effects) functions, and unused variables. They are
  266. // null except for versions of gcc that are known to support the features
  267. // properly (old versions of gcc-2 supported the dead and pure features
  268. // in a different (wrong) way). If we do not provide an implementation
  269. // for a given compiler, let the compile fail if it is told to use
  270. // a feature that we cannot live without.
  271. // Keywords added in C11.
  272. // Emulation of C11 _Generic(). Unlike the previously defined C11
  273. // keywords, it is not possible to implement this using exactly the same
  274. // syntax. Therefore implement something similar under the name
  275. // __generic(). Unlike _Generic(), this macro can only distinguish
  276. // between a single type, so it requires nested invocations to
  277. // distinguish multiple cases.
  278. // C99 Static array indices in function parameter declarations. Syntax such as:
  279. // void bar(int myArray[static 10]);
  280. // is allowed in C99 but not in C++. Define __min_size appropriately so
  281. // headers using it can be compiled in either language. Use like this:
  282. // void bar(int myArray[__min_size(10)]);
  283. // XXX: should use `#if __STDC_VERSION__ < 199901'.
  284. // C++11 exposes a load of C99 stuff
  285. // GCC 2.95 provides `__restrict' as an extension to C90 to support the
  286. // C99-specific `restrict' type qualifier. We happen to use `__restrict' as
  287. // a way to define the `restrict' type qualifier without disturbing older
  288. // software that is unaware of C99 keywords.
  289. // GNU C version 2.96 adds explicit branch prediction so that
  290. // the CPU back-end can hint the processor and also so that
  291. // code blocks can be reordered such that the predicted path
  292. // sees a more linear flow, thus improving cache behavior, etc.
  293. //
  294. // The following two macros provide us with a way to utilize this
  295. // compiler feature. Use __predict_true() if you expect the expression
  296. // to evaluate to true, and __predict_false() if you expect the
  297. // expression to evaluate to false.
  298. //
  299. // A few notes about usage:
  300. //
  301. // * Generally, __predict_false() error condition checks (unless
  302. // you have some _strong_ reason to do otherwise, in which case
  303. // document it), and/or __predict_true() `no-error' condition
  304. // checks, assuming you want to optimize for the no-error case.
  305. //
  306. // * Other than that, if you don't know the likelihood of a test
  307. // succeeding from empirical or other `hard' evidence, don't
  308. // make predictions.
  309. //
  310. // * These are meant to be used in places that are run `a lot'.
  311. // It is wasteful to make predictions in code that is run
  312. // seldomly (e.g. at subsystem initialization time) as the
  313. // basic block reordering that this affects can often generate
  314. // larger code.
  315. // We define this here since <stddef.h>, <sys/queue.h>, and <sys/types.h>
  316. // require it.
  317. // Given the pointer x to the member m of the struct s, return
  318. // a pointer to the containing structure. When using GCC, we first
  319. // assign pointer x to a local variable, to check that its type is
  320. // compatible with member m.
  321. // Compiler-dependent macros to declare that functions take printf-like
  322. // or scanf-like arguments. They are null except for versions of gcc
  323. // that are known to support the features properly (old versions of gcc-2
  324. // didn't permit keeping the keywords out of the application namespace).
  325. // Compiler-dependent macros that rely on FreeBSD-specific extensions.
  326. // Embed the rcs id of a source file in the resulting library. Note that in
  327. // more recent ELF binutils, we use .ident allowing the ID to be stripped.
  328. // Usage:
  329. // __FBSDID("$FreeBSD$");
  330. // -
  331. // The following definitions are an extension of the behavior originally
  332. // implemented in <sys/_posix.h>, but with a different level of granularity.
  333. // POSIX.1 requires that the macros we test be defined before any standard
  334. // header file is included.
  335. //
  336. // Here's a quick run-down of the versions:
  337. // defined(_POSIX_SOURCE) 1003.1-1988
  338. // _POSIX_C_SOURCE == 1 1003.1-1990
  339. // _POSIX_C_SOURCE == 2 1003.2-1992 C Language Binding Option
  340. // _POSIX_C_SOURCE == 199309 1003.1b-1993
  341. // _POSIX_C_SOURCE == 199506 1003.1c-1995, 1003.1i-1995,
  342. // and the omnibus ISO/IEC 9945-1: 1996
  343. // _POSIX_C_SOURCE == 200112 1003.1-2001
  344. // _POSIX_C_SOURCE == 200809 1003.1-2008
  345. //
  346. // In addition, the X/Open Portability Guide, which is now the Single UNIX
  347. // Specification, defines a feature-test macro which indicates the version of
  348. // that specification, and which subsumes _POSIX_C_SOURCE.
  349. //
  350. // Our macros begin with two underscores to avoid namespace screwage.
  351. // Deal with IEEE Std. 1003.1-1990, in which _POSIX_C_SOURCE == 1.
  352. // Deal with IEEE Std. 1003.2-1992, in which _POSIX_C_SOURCE == 2.
  353. // Deal with various X/Open Portability Guides and Single UNIX Spec.
  354. // Deal with all versions of POSIX. The ordering relative to the tests above is
  355. // important.
  356. // -
  357. // Deal with _ANSI_SOURCE:
  358. // If it is defined, and no other compilation environment is explicitly
  359. // requested, then define our internal feature-test macros to zero. This
  360. // makes no difference to the preprocessor (undefined symbols in preprocessing
  361. // expressions are defined to have value zero), but makes it more convenient for
  362. // a test program to print out the values.
  363. //
  364. // If a program mistakenly defines _ANSI_SOURCE and some other macro such as
  365. // _POSIX_C_SOURCE, we will assume that it wants the broader compilation
  366. // environment (and in fact we will never get here).
  367. // User override __EXT1_VISIBLE
  368. // Old versions of GCC use non-standard ARM arch symbols; acle-compat.h
  369. // translates them to __ARM_ARCH and the modern feature symbols defined by ARM.
  370. // Nullability qualifiers: currently only supported by Clang.
  371. // Type Safety Checking
  372. //
  373. // Clang provides additional attributes to enable checking type safety
  374. // properties that cannot be enforced by the C type system.
  375. // Lock annotations.
  376. //
  377. // Clang provides support for doing basic thread-safety tests at
  378. // compile-time, by marking which locks will/should be held when
  379. // entering/leaving a functions.
  380. //
  381. // Furthermore, it is also possible to annotate variables and structure
  382. // members to enforce that they are only accessed when certain locks are
  383. // held.
  384. // Structure implements a lock.
  385. // Function acquires an exclusive or shared lock.
  386. // Function attempts to acquire an exclusive or shared lock.
  387. // Function releases a lock.
  388. // Function asserts that an exclusive or shared lock is held.
  389. // Function requires that an exclusive or shared lock is or is not held.
  390. // Function should not be analyzed.
  391. // Function or variable should not be sanitized, e.g., by AddressSanitizer.
  392. // GCC has the nosanitize attribute, but as a function attribute only, and
  393. // warns on use as a variable attribute.
  394. // Guard variables and structure members by lock.
  395. // Alignment builtins for better type checking and improved code generation.
  396. // Provide fallback versions for other compilers (GCC/Clang < 10):
  397. // -
  398. // SPDX-License-Identifier: BSD-2-Clause-FreeBSD
  399. //
  400. // Copyright (c) 2002 Mike Barcroft <mike@FreeBSD.org>
  401. // All rights reserved.
  402. //
  403. // Redistribution and use in source and binary forms, with or without
  404. // modification, are permitted provided that the following conditions
  405. // are met:
  406. // 1. Redistributions of source code must retain the above copyright
  407. // notice, this list of conditions and the following disclaimer.
  408. // 2. Redistributions in binary form must reproduce the above copyright
  409. // notice, this list of conditions and the following disclaimer in the
  410. // documentation and/or other materials provided with the distribution.
  411. //
  412. // THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  413. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  414. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  415. // ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
  416. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  417. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  418. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  419. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  420. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  421. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  422. // SUCH DAMAGE.
  423. //
  424. // $FreeBSD$
  425. // -
  426. // SPDX-License-Identifier: BSD-3-Clause
  427. //
  428. // Copyright (c) 1991, 1993
  429. // The Regents of the University of California. All rights reserved.
  430. //
  431. // This code is derived from software contributed to Berkeley by
  432. // Berkeley Software Design, Inc.
  433. //
  434. // Redistribution and use in source and binary forms, with or without
  435. // modification, are permitted provided that the following conditions
  436. // are met:
  437. // 1. Redistributions of source code must retain the above copyright
  438. // notice, this list of conditions and the following disclaimer.
  439. // 2. Redistributions in binary form must reproduce the above copyright
  440. // notice, this list of conditions and the following disclaimer in the
  441. // documentation and/or other materials provided with the distribution.
  442. // 3. Neither the name of the University nor the names of its contributors
  443. // may be used to endorse or promote products derived from this software
  444. // without specific prior written permission.
  445. //
  446. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  447. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  448. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  449. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  450. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  451. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  452. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  453. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  454. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  455. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  456. // SUCH DAMAGE.
  457. //
  458. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  459. // $FreeBSD$
  460. // -
  461. // SPDX-License-Identifier: BSD-4-Clause
  462. //
  463. // Copyright (c) 2002 Mike Barcroft <mike@FreeBSD.org>
  464. // Copyright (c) 1990, 1993
  465. // The Regents of the University of California. All rights reserved.
  466. //
  467. // Redistribution and use in source and binary forms, with or without
  468. // modification, are permitted provided that the following conditions
  469. // are met:
  470. // 1. Redistributions of source code must retain the above copyright
  471. // notice, this list of conditions and the following disclaimer.
  472. // 2. Redistributions in binary form must reproduce the above copyright
  473. // notice, this list of conditions and the following disclaimer in the
  474. // documentation and/or other materials provided with the distribution.
  475. // 3. All advertising materials mentioning features or use of this software
  476. // must display the following acknowledgement:
  477. // This product includes software developed by the University of
  478. // California, Berkeley and its contributors.
  479. // 4. Neither the name of the University nor the names of its contributors
  480. // may be used to endorse or promote products derived from this software
  481. // without specific prior written permission.
  482. //
  483. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  484. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  485. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  486. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  487. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  488. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  489. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  490. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  491. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  492. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  493. // SUCH DAMAGE.
  494. //
  495. // From: @(#)ansi.h 8.2 (Berkeley) 1/4/94
  496. // From: @(#)types.h 8.3 (Berkeley) 1/5/94
  497. // $FreeBSD$
  498. // Basic types upon which most other types are built.
  499. type X__int8_t = int8 /* _types.h:51:22 */
  500. type X__uint8_t = uint8 /* _types.h:52:24 */
  501. type X__int16_t = int16 /* _types.h:53:17 */
  502. type X__uint16_t = uint16 /* _types.h:54:25 */
  503. type X__int32_t = int32 /* _types.h:55:15 */
  504. type X__uint32_t = uint32 /* _types.h:56:23 */
  505. // LONGLONG
  506. type X__int64_t = int64 /* _types.h:61:20 */
  507. // LONGLONG
  508. type X__uint64_t = uint64 /* _types.h:66:28 */
  509. // Standard type definitions.
  510. type X__clock_t = X__uint32_t /* _types.h:71:20 */ // clock()...
  511. type X__critical_t = X__int32_t /* _types.h:72:19 */
  512. type X__double_t = float64 /* _types.h:74:17 */
  513. type X__float_t = float32 /* _types.h:75:16 */
  514. type X__intfptr_t = X__int32_t /* _types.h:77:19 */
  515. type X__intmax_t = X__int64_t /* _types.h:78:19 */
  516. type X__intptr_t = X__int32_t /* _types.h:79:19 */
  517. type X__int_fast8_t = X__int32_t /* _types.h:80:19 */
  518. type X__int_fast16_t = X__int32_t /* _types.h:81:19 */
  519. type X__int_fast32_t = X__int32_t /* _types.h:82:19 */
  520. type X__int_fast64_t = X__int64_t /* _types.h:83:19 */
  521. type X__int_least8_t = X__int8_t /* _types.h:84:18 */
  522. type X__int_least16_t = X__int16_t /* _types.h:85:19 */
  523. type X__int_least32_t = X__int32_t /* _types.h:86:19 */
  524. type X__int_least64_t = X__int64_t /* _types.h:87:19 */
  525. type X__ptrdiff_t = X__int32_t /* _types.h:88:19 */ // ptr1 - ptr2
  526. type X__register_t = X__int32_t /* _types.h:89:19 */
  527. type X__segsz_t = X__int32_t /* _types.h:90:19 */ // segment size (in pages)
  528. type X__size_t = X__uint32_t /* _types.h:91:20 */ // sizeof()
  529. type X__ssize_t = X__int32_t /* _types.h:92:19 */ // byte count or error
  530. type X__time_t = X__int64_t /* _types.h:93:19 */ // time()...
  531. type X__uintfptr_t = X__uint32_t /* _types.h:94:20 */
  532. type X__uintmax_t = X__uint64_t /* _types.h:95:20 */
  533. type X__uintptr_t = X__uint32_t /* _types.h:96:20 */
  534. type X__uint_fast8_t = X__uint32_t /* _types.h:97:20 */
  535. type X__uint_fast16_t = X__uint32_t /* _types.h:98:20 */
  536. type X__uint_fast32_t = X__uint32_t /* _types.h:99:20 */
  537. type X__uint_fast64_t = X__uint64_t /* _types.h:100:20 */
  538. type X__uint_least8_t = X__uint8_t /* _types.h:101:19 */
  539. type X__uint_least16_t = X__uint16_t /* _types.h:102:20 */
  540. type X__uint_least32_t = X__uint32_t /* _types.h:103:20 */
  541. type X__uint_least64_t = X__uint64_t /* _types.h:104:20 */
  542. type X__u_register_t = X__uint32_t /* _types.h:105:20 */
  543. type X__vm_offset_t = X__uint32_t /* _types.h:106:20 */
  544. type X__vm_paddr_t = X__uint32_t /* _types.h:107:20 */
  545. type X__vm_size_t = X__uint32_t /* _types.h:108:20 */
  546. type X___wchar_t = uint32 /* _types.h:110:22 */
  547. // Standard type definitions.
  548. type X__blksize_t = X__int32_t /* _types.h:40:19 */ // file block size
  549. type X__blkcnt_t = X__int64_t /* _types.h:41:19 */ // file block count
  550. type X__clockid_t = X__int32_t /* _types.h:42:19 */ // clock_gettime()...
  551. type X__fflags_t = X__uint32_t /* _types.h:43:20 */ // file flags
  552. type X__fsblkcnt_t = X__uint64_t /* _types.h:44:20 */
  553. type X__fsfilcnt_t = X__uint64_t /* _types.h:45:20 */
  554. type X__gid_t = X__uint32_t /* _types.h:46:20 */
  555. type X__id_t = X__int64_t /* _types.h:47:19 */ // can hold a gid_t, pid_t, or uid_t
  556. type X__ino_t = X__uint64_t /* _types.h:48:20 */ // inode number
  557. type X__key_t = int32 /* _types.h:49:15 */ // IPC key (for Sys V IPC)
  558. type X__lwpid_t = X__int32_t /* _types.h:50:19 */ // Thread ID (a.k.a. LWP)
  559. type X__mode_t = X__uint16_t /* _types.h:51:20 */ // permissions
  560. type X__accmode_t = int32 /* _types.h:52:14 */ // access permissions
  561. type X__nl_item = int32 /* _types.h:53:14 */
  562. type X__nlink_t = X__uint64_t /* _types.h:54:20 */ // link count
  563. type X__off_t = X__int64_t /* _types.h:55:19 */ // file offset
  564. type X__off64_t = X__int64_t /* _types.h:56:19 */ // file offset (alias)
  565. type X__pid_t = X__int32_t /* _types.h:57:19 */ // process [group]
  566. type X__rlim_t = X__int64_t /* _types.h:58:19 */ // resource limit - intentionally
  567. // signed, because of legacy code
  568. // that uses -1 for RLIM_INFINITY
  569. type X__sa_family_t = X__uint8_t /* _types.h:61:19 */
  570. type X__socklen_t = X__uint32_t /* _types.h:62:20 */
  571. type X__suseconds_t = int32 /* _types.h:63:15 */ // microseconds (signed)
  572. type X__timer_t = uintptr /* _types.h:64:24 */ // timer_gettime()...
  573. type X__mqd_t = uintptr /* _types.h:65:21 */ // mq_open()...
  574. type X__uid_t = X__uint32_t /* _types.h:66:20 */
  575. type X__useconds_t = uint32 /* _types.h:67:22 */ // microseconds (unsigned)
  576. type X__cpuwhich_t = int32 /* _types.h:68:14 */ // which parameter for cpuset.
  577. type X__cpulevel_t = int32 /* _types.h:69:14 */ // level parameter for cpuset.
  578. type X__cpusetid_t = int32 /* _types.h:70:14 */ // cpuset identifier.
  579. type X__daddr_t = X__int64_t /* _types.h:71:19 */ // bwrite(3), FIOBMAP2, etc
  580. // Unusual type definitions.
  581. // rune_t is declared to be an “int” instead of the more natural
  582. // “unsigned long” or “long”. Two things are happening here. It is not
  583. // unsigned so that EOF (-1) can be naturally assigned to it and used. Also,
  584. // it looks like 10646 will be a 31 bit standard. This means that if your
  585. // ints cannot hold 32 bits, you will be in trouble. The reason an int was
  586. // chosen over a long is that the is*() and to*() routines take ints (says
  587. // ANSI C), but they use __ct_rune_t instead of int.
  588. //
  589. // NOTE: rune_t is not covered by ANSI nor other standards, and should not
  590. // be instantiated outside of lib/libc/locale. Use wchar_t. wint_t and
  591. // rune_t must be the same type. Also, wint_t should be able to hold all
  592. // members of the largest character set plus one extra value (WEOF), and
  593. // must be at least 16 bits.
  594. type X__ct_rune_t = int32 /* _types.h:91:14 */ // arg type for ctype funcs
  595. type X__rune_t = X__ct_rune_t /* _types.h:92:21 */ // rune_t (see above)
  596. type X__wint_t = X__ct_rune_t /* _types.h:93:21 */ // wint_t (see above)
  597. // Clang already provides these types as built-ins, but only in C++ mode.
  598. type X__char16_t = X__uint_least16_t /* _types.h:97:26 */
  599. type X__char32_t = X__uint_least32_t /* _types.h:98:26 */
  600. // In C++11, char16_t and char32_t are built-in types.
  601. type X__max_align_t = struct {
  602. F__max_align1 int64
  603. F__max_align2 float64
  604. } /* _types.h:111:3 */
  605. type X__dev_t = X__uint64_t /* _types.h:113:20 */ // device number
  606. type X__fixpt_t = X__uint32_t /* _types.h:115:20 */ // fixed point number
  607. // mbstate_t is an opaque object to keep conversion state during multibyte
  608. // stream conversions.
  609. type X__mbstate_t = struct {
  610. F__ccgo_pad1 [0]uint64
  611. F__mbstate8 [128]uint8
  612. } /* _types.h:124:3 */
  613. type X__rman_res_t = X__uintmax_t /* _types.h:126:25 */
  614. // Types for varargs. These are all provided by builtin types these
  615. // days, so centralize their definition.
  616. type X__va_list = X__builtin_va_list /* _types.h:133:27 */ // internally known to gcc
  617. type X__gnuc_va_list = X__va_list /* _types.h:140:20 */ // compatibility w/GNU headers
  618. // When the following macro is defined, the system uses 64-bit inode numbers.
  619. // Programs can use this to avoid including <sys/param.h>, with its associated
  620. // namespace pollution.
  621. // -
  622. // SPDX-License-Identifier: BSD-3-Clause
  623. //
  624. // Copyright (c) 1982, 1986, 1989, 1991, 1993
  625. // The Regents of the University of California. All rights reserved.
  626. // (c) UNIX System Laboratories, Inc.
  627. // All or some portions of this file are derived from material licensed
  628. // to the University of California by American Telephone and Telegraph
  629. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  630. // the permission of UNIX System Laboratories, Inc.
  631. //
  632. // Redistribution and use in source and binary forms, with or without
  633. // modification, are permitted provided that the following conditions
  634. // are met:
  635. // 1. Redistributions of source code must retain the above copyright
  636. // notice, this list of conditions and the following disclaimer.
  637. // 2. Redistributions in binary form must reproduce the above copyright
  638. // notice, this list of conditions and the following disclaimer in the
  639. // documentation and/or other materials provided with the distribution.
  640. // 3. Neither the name of the University nor the names of its contributors
  641. // may be used to endorse or promote products derived from this software
  642. // without specific prior written permission.
  643. //
  644. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  645. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  646. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  647. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  648. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  649. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  650. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  651. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  652. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  653. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  654. // SUCH DAMAGE.
  655. //
  656. // @(#)signal.h 8.4 (Berkeley) 5/4/95
  657. // $FreeBSD$
  658. // -
  659. // SPDX-License-Identifier: BSD-3-Clause
  660. //
  661. // Copyright (c) 1991, 1993
  662. // The Regents of the University of California. All rights reserved.
  663. //
  664. // This code is derived from software contributed to Berkeley by
  665. // Berkeley Software Design, Inc.
  666. //
  667. // Redistribution and use in source and binary forms, with or without
  668. // modification, are permitted provided that the following conditions
  669. // are met:
  670. // 1. Redistributions of source code must retain the above copyright
  671. // notice, this list of conditions and the following disclaimer.
  672. // 2. Redistributions in binary form must reproduce the above copyright
  673. // notice, this list of conditions and the following disclaimer in the
  674. // documentation and/or other materials provided with the distribution.
  675. // 3. Neither the name of the University nor the names of its contributors
  676. // may be used to endorse or promote products derived from this software
  677. // without specific prior written permission.
  678. //
  679. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  680. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  681. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  682. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  683. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  684. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  685. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  686. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  687. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  688. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  689. // SUCH DAMAGE.
  690. //
  691. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  692. // $FreeBSD$
  693. // -
  694. // SPDX-License-Identifier: BSD-2-Clause-FreeBSD
  695. //
  696. // Copyright (c) 2002 Mike Barcroft <mike@FreeBSD.org>
  697. // All rights reserved.
  698. //
  699. // Redistribution and use in source and binary forms, with or without
  700. // modification, are permitted provided that the following conditions
  701. // are met:
  702. // 1. Redistributions of source code must retain the above copyright
  703. // notice, this list of conditions and the following disclaimer.
  704. // 2. Redistributions in binary form must reproduce the above copyright
  705. // notice, this list of conditions and the following disclaimer in the
  706. // documentation and/or other materials provided with the distribution.
  707. //
  708. // THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  709. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  710. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  711. // ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
  712. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  713. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  714. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  715. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  716. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  717. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  718. // SUCH DAMAGE.
  719. //
  720. // $FreeBSD$
  721. // -
  722. // SPDX-License-Identifier: BSD-3-Clause
  723. //
  724. // Copyright (c) 1982, 1986, 1989, 1991, 1993
  725. // The Regents of the University of California. All rights reserved.
  726. // (c) UNIX System Laboratories, Inc.
  727. // All or some portions of this file are derived from material licensed
  728. // to the University of California by American Telephone and Telegraph
  729. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  730. // the permission of UNIX System Laboratories, Inc.
  731. //
  732. // Redistribution and use in source and binary forms, with or without
  733. // modification, are permitted provided that the following conditions
  734. // are met:
  735. // 1. Redistributions of source code must retain the above copyright
  736. // notice, this list of conditions and the following disclaimer.
  737. // 2. Redistributions in binary form must reproduce the above copyright
  738. // notice, this list of conditions and the following disclaimer in the
  739. // documentation and/or other materials provided with the distribution.
  740. // 3. Neither the name of the University nor the names of its contributors
  741. // may be used to endorse or promote products derived from this software
  742. // without specific prior written permission.
  743. //
  744. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  745. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  746. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  747. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  748. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  749. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  750. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  751. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  752. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  753. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  754. // SUCH DAMAGE.
  755. //
  756. // @(#)signal.h 8.4 (Berkeley) 5/4/95
  757. // $FreeBSD$
  758. // sigset_t macros.
  759. type X__sigset = struct{ F__bits [4]X__uint32_t } /* _sigset.h:53:9 */
  760. // compatibility w/GNU headers
  761. // When the following macro is defined, the system uses 64-bit inode numbers.
  762. // Programs can use this to avoid including <sys/param.h>, with its associated
  763. // namespace pollution.
  764. // -
  765. // SPDX-License-Identifier: BSD-3-Clause
  766. //
  767. // Copyright (c) 1982, 1986, 1989, 1991, 1993
  768. // The Regents of the University of California. All rights reserved.
  769. // (c) UNIX System Laboratories, Inc.
  770. // All or some portions of this file are derived from material licensed
  771. // to the University of California by American Telephone and Telegraph
  772. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  773. // the permission of UNIX System Laboratories, Inc.
  774. //
  775. // Redistribution and use in source and binary forms, with or without
  776. // modification, are permitted provided that the following conditions
  777. // are met:
  778. // 1. Redistributions of source code must retain the above copyright
  779. // notice, this list of conditions and the following disclaimer.
  780. // 2. Redistributions in binary form must reproduce the above copyright
  781. // notice, this list of conditions and the following disclaimer in the
  782. // documentation and/or other materials provided with the distribution.
  783. // 3. Neither the name of the University nor the names of its contributors
  784. // may be used to endorse or promote products derived from this software
  785. // without specific prior written permission.
  786. //
  787. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  788. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  789. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  790. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  791. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  792. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  793. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  794. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  795. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  796. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  797. // SUCH DAMAGE.
  798. //
  799. // @(#)signal.h 8.4 (Berkeley) 5/4/95
  800. // $FreeBSD$
  801. // -
  802. // SPDX-License-Identifier: BSD-3-Clause
  803. //
  804. // Copyright (c) 1991, 1993
  805. // The Regents of the University of California. All rights reserved.
  806. //
  807. // This code is derived from software contributed to Berkeley by
  808. // Berkeley Software Design, Inc.
  809. //
  810. // Redistribution and use in source and binary forms, with or without
  811. // modification, are permitted provided that the following conditions
  812. // are met:
  813. // 1. Redistributions of source code must retain the above copyright
  814. // notice, this list of conditions and the following disclaimer.
  815. // 2. Redistributions in binary form must reproduce the above copyright
  816. // notice, this list of conditions and the following disclaimer in the
  817. // documentation and/or other materials provided with the distribution.
  818. // 3. Neither the name of the University nor the names of its contributors
  819. // may be used to endorse or promote products derived from this software
  820. // without specific prior written permission.
  821. //
  822. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  823. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  824. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  825. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  826. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  827. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  828. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  829. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  830. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  831. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  832. // SUCH DAMAGE.
  833. //
  834. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  835. // $FreeBSD$
  836. // -
  837. // SPDX-License-Identifier: BSD-2-Clause-FreeBSD
  838. //
  839. // Copyright (c) 2002 Mike Barcroft <mike@FreeBSD.org>
  840. // All rights reserved.
  841. //
  842. // Redistribution and use in source and binary forms, with or without
  843. // modification, are permitted provided that the following conditions
  844. // are met:
  845. // 1. Redistributions of source code must retain the above copyright
  846. // notice, this list of conditions and the following disclaimer.
  847. // 2. Redistributions in binary form must reproduce the above copyright
  848. // notice, this list of conditions and the following disclaimer in the
  849. // documentation and/or other materials provided with the distribution.
  850. //
  851. // THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  852. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  853. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  854. // ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
  855. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  856. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  857. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  858. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  859. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  860. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  861. // SUCH DAMAGE.
  862. //
  863. // $FreeBSD$
  864. // -
  865. // SPDX-License-Identifier: BSD-3-Clause
  866. //
  867. // Copyright (c) 1982, 1986, 1989, 1991, 1993
  868. // The Regents of the University of California. All rights reserved.
  869. // (c) UNIX System Laboratories, Inc.
  870. // All or some portions of this file are derived from material licensed
  871. // to the University of California by American Telephone and Telegraph
  872. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  873. // the permission of UNIX System Laboratories, Inc.
  874. //
  875. // Redistribution and use in source and binary forms, with or without
  876. // modification, are permitted provided that the following conditions
  877. // are met:
  878. // 1. Redistributions of source code must retain the above copyright
  879. // notice, this list of conditions and the following disclaimer.
  880. // 2. Redistributions in binary form must reproduce the above copyright
  881. // notice, this list of conditions and the following disclaimer in the
  882. // documentation and/or other materials provided with the distribution.
  883. // 3. Neither the name of the University nor the names of its contributors
  884. // may be used to endorse or promote products derived from this software
  885. // without specific prior written permission.
  886. //
  887. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  888. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  889. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  890. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  891. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  892. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  893. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  894. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  895. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  896. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  897. // SUCH DAMAGE.
  898. //
  899. // @(#)signal.h 8.4 (Berkeley) 5/4/95
  900. // $FreeBSD$
  901. // sigset_t macros.
  902. type X__sigset_t = X__sigset /* _sigset.h:55:3 */
  903. // -
  904. // SPDX-License-Identifier: BSD-3-Clause
  905. //
  906. // Copyright (c) 1988, 1993
  907. // The Regents of the University of California. All rights reserved.
  908. //
  909. // Redistribution and use in source and binary forms, with or without
  910. // modification, are permitted provided that the following conditions
  911. // are met:
  912. // 1. Redistributions of source code must retain the above copyright
  913. // notice, this list of conditions and the following disclaimer.
  914. // 2. Redistributions in binary form must reproduce the above copyright
  915. // notice, this list of conditions and the following disclaimer in the
  916. // documentation and/or other materials provided with the distribution.
  917. // 3. Neither the name of the University nor the names of its contributors
  918. // may be used to endorse or promote products derived from this software
  919. // without specific prior written permission.
  920. //
  921. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  922. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  923. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  924. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  925. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  926. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  927. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  928. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  929. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  930. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  931. // SUCH DAMAGE.
  932. //
  933. // @(#)limits.h 8.3 (Berkeley) 1/4/94
  934. // $FreeBSD$
  935. // According to ANSI (section 2.2.4.2), the values below must be usable by
  936. // #if preprocessing directives. Additionally, the expression must have the
  937. // same type as would an expression that is an object of the corresponding
  938. // type converted according to the integral promotions. The subtraction for
  939. // INT_MIN, etc., is so the value is not unsigned; e.g., 0x80000000 is an
  940. // unsigned int for 32-bit two's complement ANSI compilers (section 3.1.3.2).
  941. // max value for an unsigned long long
  942. // Quads and long longs are the same size. Ensure they stay in sync.
  943. // Minimum signal stack size.
  944. // -
  945. // SPDX-License-Identifier: BSD-3-Clause
  946. //
  947. // Copyright (c) 1986, 1989, 1991, 1993
  948. // The Regents of the University of California. All rights reserved.
  949. //
  950. // Redistribution and use in source and binary forms, with or without
  951. // modification, are permitted provided that the following conditions
  952. // are met:
  953. // 1. Redistributions of source code must retain the above copyright
  954. // notice, this list of conditions and the following disclaimer.
  955. // 2. Redistributions in binary form must reproduce the above copyright
  956. // notice, this list of conditions and the following disclaimer in the
  957. // documentation and/or other materials provided with the distribution.
  958. // 3. Neither the name of the University nor the names of its contributors
  959. // may be used to endorse or promote products derived from this software
  960. // without specific prior written permission.
  961. //
  962. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  963. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  964. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  965. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  966. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  967. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  968. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  969. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  970. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  971. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  972. // SUCH DAMAGE.
  973. //
  974. // @(#)signal.h 8.1 (Berkeley) 6/11/93
  975. // from: FreeBSD: src/sys/i386/include/signal.h,v 1.13 2000/11/09
  976. // from: FreeBSD: src/sys/sparc64/include/signal.h,v 1.6 2001/09/30 18:52:17
  977. // $FreeBSD$
  978. // -
  979. // SPDX-License-Identifier: BSD-3-Clause
  980. //
  981. // Copyright (c) 1991, 1993
  982. // The Regents of the University of California. All rights reserved.
  983. //
  984. // This code is derived from software contributed to Berkeley by
  985. // Berkeley Software Design, Inc.
  986. //
  987. // Redistribution and use in source and binary forms, with or without
  988. // modification, are permitted provided that the following conditions
  989. // are met:
  990. // 1. Redistributions of source code must retain the above copyright
  991. // notice, this list of conditions and the following disclaimer.
  992. // 2. Redistributions in binary form must reproduce the above copyright
  993. // notice, this list of conditions and the following disclaimer in the
  994. // documentation and/or other materials provided with the distribution.
  995. // 3. Neither the name of the University nor the names of its contributors
  996. // may be used to endorse or promote products derived from this software
  997. // without specific prior written permission.
  998. //
  999. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1000. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1001. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1002. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1003. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1004. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1005. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1006. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1007. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1008. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1009. // SUCH DAMAGE.
  1010. //
  1011. // @(#)cdefs.h 8.8 (Berkeley) 1/9/95
  1012. // $FreeBSD$
  1013. type Sig_atomic_t = int32 /* signal.h:42:14 */
  1014. type Sigcontext = struct{ F_dummy int32 } /* signal.h:46:1 */
  1015. type Pthread_once = struct {
  1016. Fstate int32
  1017. Fmutex Pthread_mutex_t
  1018. } /* _pthreadtypes.h:52:1 */
  1019. // Primitive system data type definitions required by P1003.1c.
  1020. //
  1021. // Note that P1003.1c specifies that there are no defined comparison
  1022. // or assignment operators for the types pthread_attr_t, pthread_cond_t,
  1023. // pthread_condattr_t, pthread_mutex_t, pthread_mutexattr_t.
  1024. type Pthread_t = uintptr /* _pthreadtypes.h:67:26 */
  1025. type Pthread_attr_t = uintptr /* _pthreadtypes.h:70:30 */
  1026. type Pthread_mutex_t = uintptr /* _pthreadtypes.h:71:31 */
  1027. type Pthread_mutexattr_t = uintptr /* _pthreadtypes.h:72:35 */
  1028. type Pthread_cond_t = uintptr /* _pthreadtypes.h:73:30 */
  1029. type Pthread_condattr_t = uintptr /* _pthreadtypes.h:74:34 */
  1030. type Pthread_key_t = int32 /* _pthreadtypes.h:75:20 */
  1031. type Pthread_once_t = Pthread_once /* _pthreadtypes.h:76:30 */
  1032. type Pthread_rwlock_t = uintptr /* _pthreadtypes.h:77:32 */
  1033. type Pthread_rwlockattr_t = uintptr /* _pthreadtypes.h:78:35 */
  1034. type Pthread_barrier_t = uintptr /* _pthreadtypes.h:79:33 */
  1035. type Pthread_barrierattr_t = uintptr /* _pthreadtypes.h:80:36 */
  1036. type Pthread_spinlock_t = uintptr /* _pthreadtypes.h:81:33 */
  1037. // Additional type definitions:
  1038. //
  1039. // Note that P1003.1c reserves the prefixes pthread_ and PTHREAD_ for
  1040. // use in header symbols.
  1041. type Pthread_addr_t = uintptr /* _pthreadtypes.h:89:14 */
  1042. type Pthread_startroutine_t = uintptr /* _pthreadtypes.h:90:14 */
  1043. // -
  1044. // SPDX-License-Identifier: BSD-3-Clause
  1045. //
  1046. // Copyright (c) 1982, 1986, 1993
  1047. // The Regents of the University of California. All rights reserved.
  1048. //
  1049. // Redistribution and use in source and binary forms, with or without
  1050. // modification, are permitted provided that the following conditions
  1051. // are met:
  1052. // 1. Redistributions of source code must retain the above copyright
  1053. // notice, this list of conditions and the following disclaimer.
  1054. // 2. Redistributions in binary form must reproduce the above copyright
  1055. // notice, this list of conditions and the following disclaimer in the
  1056. // documentation and/or other materials provided with the distribution.
  1057. // 3. Neither the name of the University nor the names of its contributors
  1058. // may be used to endorse or promote products derived from this software
  1059. // without specific prior written permission.
  1060. //
  1061. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1062. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1063. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1064. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1065. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1066. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1067. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1068. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1069. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1070. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1071. // SUCH DAMAGE.
  1072. //
  1073. // @(#)time.h 8.5 (Berkeley) 5/4/95
  1074. // from: FreeBSD: src/sys/sys/time.h,v 1.43 2000/03/20 14:09:05 phk Exp
  1075. // $FreeBSD$
  1076. // -
  1077. // SPDX-License-Identifier: BSD-2-Clause-FreeBSD
  1078. //
  1079. // Copyright (c) 2002 Mike Barcroft <mike@FreeBSD.org>
  1080. // All rights reserved.
  1081. //
  1082. // Redistribution and use in source and binary forms, with or without
  1083. // modification, are permitted provided that the following conditions
  1084. // are met:
  1085. // 1. Redistributions of source code must retain the above copyright
  1086. // notice, this list of conditions and the following disclaimer.
  1087. // 2. Redistributions in binary form must reproduce the above copyright
  1088. // notice, this list of conditions and the following disclaimer in the
  1089. // documentation and/or other materials provided with the distribution.
  1090. //
  1091. // THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  1092. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1093. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1094. // ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
  1095. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1096. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1097. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1098. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1099. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1100. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1101. // SUCH DAMAGE.
  1102. //
  1103. // $FreeBSD$
  1104. type Time_t = X__time_t /* _timespec.h:42:18 */
  1105. type Timespec = struct {
  1106. Ftv_sec Time_t
  1107. Ftv_nsec int32
  1108. F__ccgo_pad1 [4]byte
  1109. } /* _timespec.h:46:1 */
  1110. type Uid_t = X__uid_t /* signal.h:61:18 */
  1111. type Sigset_t = X__sigset_t /* signal.h:166:20 */
  1112. type Sigval = struct{ Fsival_int int32 } /* signal.h:171:1 */
  1113. type Sigevent = struct {
  1114. Fsigev_notify int32
  1115. Fsigev_signo int32
  1116. Fsigev_value struct{ Fsival_int int32 }
  1117. F_sigev_un struct {
  1118. F_threadid X__lwpid_t
  1119. F__ccgo_pad1 [28]byte
  1120. }
  1121. } /* signal.h:195:1 */
  1122. type X__siginfo = struct {
  1123. Fsi_signo int32
  1124. Fsi_errno int32
  1125. Fsi_code int32
  1126. Fsi_pid X__pid_t
  1127. Fsi_uid X__uid_t
  1128. Fsi_status int32
  1129. Fsi_addr uintptr
  1130. Fsi_value struct{ Fsival_int int32 }
  1131. F_reason struct {
  1132. F_fault struct{ F_trapno int32 }
  1133. F__ccgo_pad1 [28]byte
  1134. }
  1135. } /* signal.h:229:9 */
  1136. type Siginfo_t = X__siginfo /* signal.h:263:3 */
  1137. // Signal vector "template" used in sigaction call.
  1138. type Sigaction = struct {
  1139. F__sigaction_u struct{ F__sa_handler uintptr }
  1140. Fsa_flags int32
  1141. Fsa_mask Sigset_t
  1142. } /* signal.h:368:1 */
  1143. // If SA_SIGINFO is set, sa_sigaction must be used instead of sa_handler.
  1144. // a timer set by timer_settime().
  1145. // an asynchronous I/O request.
  1146. // message on an empty message queue.
  1147. type Sig_t = uintptr /* signal.h:420:24 */
  1148. type Sigaltstack = struct {
  1149. Fss_sp uintptr
  1150. Fss_size X__size_t
  1151. Fss_flags int32
  1152. } /* signal.h:428:9 */
  1153. type Stack_t = Sigaltstack /* signal.h:428:26 */
  1154. // 4.3 compatibility:
  1155. // Signal vector "template" used in sigvec call.
  1156. type Sigvec = struct {
  1157. Fsv_handler uintptr
  1158. Fsv_mask int32
  1159. Fsv_flags int32
  1160. } /* signal.h:452:1 */
  1161. // Keep this in one place only
  1162. // Structure used in sigstack call.
  1163. type Sigstack = struct {
  1164. Fss_sp uintptr
  1165. Fss_onstack int32
  1166. } /* signal.h:479:1 */
  1167. // $NetBSD: mcontext.h,v 1.4 2003/10/08 22:43:01 thorpej Exp $
  1168. // -
  1169. // SPDX-License-Identifier: BSD-2-Clause-NetBSD
  1170. //
  1171. // Copyright (c) 2001, 2002 The NetBSD Foundation, Inc.
  1172. // All rights reserved.
  1173. //
  1174. // This code is derived from software contributed to The NetBSD Foundation
  1175. // by Klaus Klein and by Jason R. Thorpe of Wasabi Systems, Inc.
  1176. //
  1177. // Redistribution and use in source and binary forms, with or without
  1178. // modification, are permitted provided that the following conditions
  1179. // are met:
  1180. // 1. Redistributions of source code must retain the above copyright
  1181. // notice, this list of conditions and the following disclaimer.
  1182. // 2. Redistributions in binary form must reproduce the above copyright
  1183. // notice, this list of conditions and the following disclaimer in the
  1184. // documentation and/or other materials provided with the distribution.
  1185. //
  1186. // THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  1187. // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
  1188. // TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  1189. // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
  1190. // BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  1191. // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  1192. // SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  1193. // INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  1194. // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  1195. // ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  1196. // POSSIBILITY OF SUCH DAMAGE.
  1197. //
  1198. // $FreeBSD$
  1199. // General register state
  1200. type X__greg_t = uint32 /* ucontext.h:42:22 */
  1201. type X__gregset_t = [17]X__greg_t /* ucontext.h:43:18 */
  1202. // Convenience synonyms
  1203. // Floating point register state
  1204. type Mcontext_vfp_t = struct {
  1205. Fmcv_reg [32]X__uint64_t
  1206. Fmcv_fpscr X__uint32_t
  1207. F__ccgo_pad1 [4]byte
  1208. } /* ucontext.h:74:3 */
  1209. type Mcontext_t = struct {
  1210. F__gregs X__gregset_t
  1211. Fmc_vfp_size X__size_t
  1212. Fmc_vfp_ptr uintptr
  1213. Fmc_spare [33]uint32
  1214. } /* ucontext.h:86:3 */
  1215. // -
  1216. // SPDX-License-Identifier: BSD-3-Clause
  1217. //
  1218. // Copyright (c) 1999 Marcel Moolenaar
  1219. // All rights reserved.
  1220. //
  1221. // Redistribution and use in source and binary forms, with or without
  1222. // modification, are permitted provided that the following conditions
  1223. // are met:
  1224. // 1. Redistributions of source code must retain the above copyright
  1225. // notice, this list of conditions and the following disclaimer
  1226. // in this position and unchanged.
  1227. // 2. Redistributions in binary form must reproduce the above copyright
  1228. // notice, this list of conditions and the following disclaimer in the
  1229. // documentation and/or other materials provided with the distribution.
  1230. // 3. The name of the author may not be used to endorse or promote products
  1231. // derived from this software without specific prior written permission.
  1232. //
  1233. // THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
  1234. // IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  1235. // OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  1236. // IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
  1237. // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  1238. // NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  1239. // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  1240. // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  1241. // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  1242. // THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  1243. //
  1244. // $FreeBSD$
  1245. type X__ucontext = struct {
  1246. Fuc_sigmask X__sigset_t
  1247. Fuc_mcontext Mcontext_t
  1248. Fuc_link uintptr
  1249. Fuc_stack struct {
  1250. Fss_sp uintptr
  1251. Fss_size X__size_t
  1252. Fss_flags int32
  1253. }
  1254. Fuc_flags int32
  1255. F__spare__ [4]int32
  1256. } /* _ucontext.h:36:9 */
  1257. // -
  1258. // SPDX-License-Identifier: BSD-3-Clause
  1259. //
  1260. // Copyright (c) 1999 Marcel Moolenaar
  1261. // All rights reserved.
  1262. //
  1263. // Redistribution and use in source and binary forms, with or without
  1264. // modification, are permitted provided that the following conditions
  1265. // are met:
  1266. // 1. Redistributions of source code must retain the above copyright
  1267. // notice, this list of conditions and the following disclaimer
  1268. // in this position and unchanged.
  1269. // 2. Redistributions in binary form must reproduce the above copyright
  1270. // notice, this list of conditions and the following disclaimer in the
  1271. // documentation and/or other materials provided with the distribution.
  1272. // 3. The name of the author may not be used to endorse or promote products
  1273. // derived from this software without specific prior written permission.
  1274. //
  1275. // THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
  1276. // IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  1277. // OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  1278. // IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
  1279. // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  1280. // NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  1281. // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  1282. // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  1283. // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  1284. // THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  1285. //
  1286. // $FreeBSD$
  1287. type Ucontext_t = X__ucontext /* _ucontext.h:52:3 */
  1288. type Pid_t = X__pid_t /* signal.h:60:18 */ // XXX
  1289. type X__pthread_t = uintptr /* signal.h:67:24 */
  1290. var _ uint8 /* gen.c:2:13: */