stdlib_openbsd_386.go 35 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770
  1. // Code generated by 'ccgo stdlib/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 stdlib/stdlib_openbsd_386.go -pkgname stdlib', DO NOT EDIT.
  2. package stdlib
  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. BIG_ENDIAN = 4321 // endian.h:45:1:
  15. BYTE_ORDER = 1234 // endian.h:47:1:
  16. EXIT_FAILURE = 1 // stdlib.h:80:1:
  17. EXIT_SUCCESS = 0 // stdlib.h:81:1:
  18. LITTLE_ENDIAN = 1234 // endian.h:44:1:
  19. PDP_ENDIAN = 3412 // endian.h:46:1:
  20. RAND_MAX = 0x7fffffff // stdlib.h:83:1:
  21. X_BIG_ENDIAN = 4321 // _endian.h:43:1:
  22. X_BYTE_ORDER = 1234 // endian.h:58:1:
  23. X_CLOCKID_T_DEFINED_ = 0 // types.h:162:1:
  24. X_CLOCK_T_DEFINED_ = 0 // types.h:157:1:
  25. X_FILE_OFFSET_BITS = 64 // <builtin>:25:1:
  26. X_ILP32 = 1 // <predefined>:1:1:
  27. X_INT16_T_DEFINED_ = 0 // types.h:84:1:
  28. X_INT32_T_DEFINED_ = 0 // types.h:94:1:
  29. X_INT64_T_DEFINED_ = 0 // types.h:104:1:
  30. X_INT8_T_DEFINED_ = 0 // types.h:74:1:
  31. X_LITTLE_ENDIAN = 1234 // _endian.h:42:1:
  32. X_MACHINE_CDEFS_H_ = 0 // cdefs.h:9:1:
  33. X_MACHINE_ENDIAN_H_ = 0 // endian.h:28:1:
  34. X_MACHINE__TYPES_H_ = 0 // _types.h:36:1:
  35. X_MAX_PAGE_SHIFT = 12 // _types.h:52:1:
  36. X_OFF_T_DEFINED_ = 0 // types.h:192:1:
  37. X_PDP_ENDIAN = 3412 // _endian.h:44:1:
  38. X_PID_T_DEFINED_ = 0 // types.h:167:1:
  39. X_QUAD_HIGHWORD = 1 // _endian.h:95:1:
  40. X_QUAD_LOWWORD = 0 // _endian.h:96:1:
  41. X_SIZE_T_DEFINED_ = 0 // types.h:172:1:
  42. X_SSIZE_T_DEFINED_ = 0 // types.h:177:1:
  43. X_STACKALIGNBYTES = 15 // _types.h:49:1:
  44. X_STDLIB_H_ = 0 // stdlib.h:36:1:
  45. X_SYS_CDEFS_H_ = 0 // cdefs.h:39:1:
  46. X_SYS_ENDIAN_H_ = 0 // endian.h:38:1:
  47. X_SYS_TYPES_H_ = 0 // types.h:41:1:
  48. X_SYS__ENDIAN_H_ = 0 // _endian.h:34:1:
  49. X_SYS__TYPES_H_ = 0 // _types.h:35:1:
  50. X_TIMER_T_DEFINED_ = 0 // types.h:187:1:
  51. X_TIME_T_DEFINED_ = 0 // types.h:182:1:
  52. X_UINT16_T_DEFINED_ = 0 // types.h:89:1:
  53. X_UINT32_T_DEFINED_ = 0 // types.h:99:1:
  54. X_UINT64_T_DEFINED_ = 0 // types.h:109:1:
  55. X_UINT8_T_DEFINED_ = 0 // types.h:79:1:
  56. X_WCHAR_T_DEFINED_ = 0 // stdlib.h:52:1:
  57. I386 = 1 // <predefined>:339:1:
  58. Unix = 1 // <predefined>:340:1:
  59. )
  60. type Ptrdiff_t = int32 /* <builtin>:3:26 */
  61. type Size_t = uint32 /* <builtin>:9:23 */
  62. type Wchar_t = int32 /* <builtin>:15:24 */
  63. type X__builtin_va_list = uintptr /* <builtin>:46:14 */
  64. type X__float128 = float64 /* <builtin>:47:21 */
  65. // $OpenBSD: stdlib.h,v 1.76 2019/05/10 15:03:24 otto Exp $
  66. // $NetBSD: stdlib.h,v 1.25 1995/12/27 21:19:08 jtc Exp $
  67. // -
  68. // Copyright (c) 1990 The Regents of the University of California.
  69. // All rights reserved.
  70. //
  71. // Redistribution and use in source and binary forms, with or without
  72. // modification, are permitted provided that the following conditions
  73. // are met:
  74. // 1. Redistributions of source code must retain the above copyright
  75. // notice, this list of conditions and the following disclaimer.
  76. // 2. Redistributions in binary form must reproduce the above copyright
  77. // notice, this list of conditions and the following disclaimer in the
  78. // documentation and/or other materials provided with the distribution.
  79. // 3. Neither the name of the University nor the names of its contributors
  80. // may be used to endorse or promote products derived from this software
  81. // without specific prior written permission.
  82. //
  83. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  84. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  85. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  86. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  87. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  88. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  89. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  90. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  91. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  92. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  93. // SUCH DAMAGE.
  94. //
  95. // @(#)stdlib.h 5.13 (Berkeley) 6/4/91
  96. // $OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  97. // $NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  98. // Copyright (c) 1991, 1993
  99. // The Regents of the University of California. All rights reserved.
  100. //
  101. // This code is derived from software contributed to Berkeley by
  102. // Berkeley Software Design, Inc.
  103. //
  104. // Redistribution and use in source and binary forms, with or without
  105. // modification, are permitted provided that the following conditions
  106. // are met:
  107. // 1. Redistributions of source code must retain the above copyright
  108. // notice, this list of conditions and the following disclaimer.
  109. // 2. Redistributions in binary form must reproduce the above copyright
  110. // notice, this list of conditions and the following disclaimer in the
  111. // documentation and/or other materials provided with the distribution.
  112. // 3. Neither the name of the University nor the names of its contributors
  113. // may be used to endorse or promote products derived from this software
  114. // without specific prior written permission.
  115. //
  116. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  117. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  118. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  119. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  120. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  121. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  122. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  123. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  124. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  125. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  126. // SUCH DAMAGE.
  127. //
  128. // @(#)cdefs.h 8.7 (Berkeley) 1/21/94
  129. // $OpenBSD: cdefs.h,v 1.10 2013/03/28 17:30:45 martynas Exp $
  130. // Written by J.T. Conklin <jtc@wimsey.com> 01/17/95.
  131. // Public domain.
  132. // Macro to test if we're using a specific version of gcc or later.
  133. // The __CONCAT macro is used to concatenate parts of symbol names, e.g.
  134. // with "#define OLD(foo) __CONCAT(old,foo)", OLD(foo) produces oldfoo.
  135. // The __CONCAT macro is a bit tricky -- make sure you don't put spaces
  136. // in between its arguments. Do not use __CONCAT on double-quoted strings,
  137. // such as those from the __STRING macro: to concatenate strings just put
  138. // them next to each other.
  139. // GCC1 and some versions of GCC2 declare dead (non-returning) and
  140. // pure (no side effects) functions using "volatile" and "const";
  141. // unfortunately, these then cause warnings under "-ansi -pedantic".
  142. // GCC >= 2.5 uses the __attribute__((attrs)) style. All of these
  143. // work for GNU C++ (modulo a slight glitch in the C++ grammar in
  144. // the distribution version of 2.5.5).
  145. // __returns_twice makes the compiler not assume the function
  146. // only returns once. This affects registerisation of variables:
  147. // even local variables need to be in memory across such a call.
  148. // Example: setjmp()
  149. // __only_inline makes the compiler only use this function definition
  150. // for inlining; references that can't be inlined will be left as
  151. // external references instead of generating a local copy. The
  152. // matching library should include a simple extern definition for
  153. // the function to handle those references. c.f. ctype.h
  154. // GNU C version 2.96 adds explicit branch prediction so that
  155. // the CPU back-end can hint the processor and also so that
  156. // code blocks can be reordered such that the predicted path
  157. // sees a more linear flow, thus improving cache behavior, etc.
  158. //
  159. // The following two macros provide us with a way to utilize this
  160. // compiler feature. Use __predict_true() if you expect the expression
  161. // to evaluate to true, and __predict_false() if you expect the
  162. // expression to evaluate to false.
  163. //
  164. // A few notes about usage:
  165. //
  166. // * Generally, __predict_false() error condition checks (unless
  167. // you have some _strong_ reason to do otherwise, in which case
  168. // document it), and/or __predict_true() `no-error' condition
  169. // checks, assuming you want to optimize for the no-error case.
  170. //
  171. // * Other than that, if you don't know the likelihood of a test
  172. // succeeding from empirical or other `hard' evidence, don't
  173. // make predictions.
  174. //
  175. // * These are meant to be used in places that are run `a lot'.
  176. // It is wasteful to make predictions in code that is run
  177. // seldomly (e.g. at subsystem initialization time) as the
  178. // basic block reordering that this affects can often generate
  179. // larger code.
  180. // Delete pseudo-keywords wherever they are not available or needed.
  181. // The __packed macro indicates that a variable or structure members
  182. // should have the smallest possible alignment, despite any host CPU
  183. // alignment requirements.
  184. //
  185. // The __aligned(x) macro specifies the minimum alignment of a
  186. // variable or structure.
  187. //
  188. // These macros together are useful for describing the layout and
  189. // alignment of messages exchanged with hardware or other systems.
  190. // "The nice thing about standards is that there are so many to choose from."
  191. // There are a number of "feature test macros" specified by (different)
  192. // standards that determine which interfaces and types the header files
  193. // should expose.
  194. //
  195. // Because of inconsistencies in these macros, we define our own
  196. // set in the private name space that end in _VISIBLE. These are
  197. // always defined and so headers can test their values easily.
  198. // Things can get tricky when multiple feature macros are defined.
  199. // We try to take the union of all the features requested.
  200. //
  201. // The following macros are guaranteed to have a value after cdefs.h
  202. // has been included:
  203. // __POSIX_VISIBLE
  204. // __XPG_VISIBLE
  205. // __ISO_C_VISIBLE
  206. // __BSD_VISIBLE
  207. // X/Open Portability Guides and Single Unix Specifications.
  208. // _XOPEN_SOURCE XPG3
  209. // _XOPEN_SOURCE && _XOPEN_VERSION = 4 XPG4
  210. // _XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED = 1 XPG4v2
  211. // _XOPEN_SOURCE == 500 XPG5
  212. // _XOPEN_SOURCE == 520 XPG5v2
  213. // _XOPEN_SOURCE == 600 POSIX 1003.1-2001 with XSI
  214. // _XOPEN_SOURCE == 700 POSIX 1003.1-2008 with XSI
  215. //
  216. // The XPG spec implies a specific value for _POSIX_C_SOURCE.
  217. // POSIX macros, these checks must follow the XOPEN ones above.
  218. //
  219. // _POSIX_SOURCE == 1 1003.1-1988 (superseded by _POSIX_C_SOURCE)
  220. // _POSIX_C_SOURCE == 1 1003.1-1990
  221. // _POSIX_C_SOURCE == 2 1003.2-1992
  222. // _POSIX_C_SOURCE == 199309L 1003.1b-1993
  223. // _POSIX_C_SOURCE == 199506L 1003.1c-1995, 1003.1i-1995,
  224. // and the omnibus ISO/IEC 9945-1:1996
  225. // _POSIX_C_SOURCE == 200112L 1003.1-2001
  226. // _POSIX_C_SOURCE == 200809L 1003.1-2008
  227. //
  228. // The POSIX spec implies a specific value for __ISO_C_VISIBLE, though
  229. // this may be overridden by the _ISOC99_SOURCE macro later.
  230. // _ANSI_SOURCE means to expose ANSI C89 interfaces only.
  231. // If the user defines it in addition to one of the POSIX or XOPEN
  232. // macros, assume the POSIX/XOPEN macro(s) should take precedence.
  233. // _ISOC99_SOURCE, _ISOC11_SOURCE, __STDC_VERSION__, and __cplusplus
  234. // override any of the other macros since they are non-exclusive.
  235. // Finally deal with BSD-specific interfaces that are not covered
  236. // by any standards. We expose these when none of the POSIX or XPG
  237. // macros is defined or if the user explicitly asks for them.
  238. // Default values.
  239. // $OpenBSD: _null.h,v 1.2 2016/09/09 22:07:58 millert Exp $
  240. // Written by Todd C. Miller, September 9, 2016
  241. // Public domain.
  242. // $OpenBSD: _types.h,v 1.23 2018/03/05 01:15:25 deraadt Exp $
  243. // -
  244. // Copyright (c) 1990, 1993
  245. // The Regents of the University of California. All rights reserved.
  246. //
  247. // Redistribution and use in source and binary forms, with or without
  248. // modification, are permitted provided that the following conditions
  249. // are met:
  250. // 1. Redistributions of source code must retain the above copyright
  251. // notice, this list of conditions and the following disclaimer.
  252. // 2. Redistributions in binary form must reproduce the above copyright
  253. // notice, this list of conditions and the following disclaimer in the
  254. // documentation and/or other materials provided with the distribution.
  255. // 3. Neither the name of the University nor the names of its contributors
  256. // may be used to endorse or promote products derived from this software
  257. // without specific prior written permission.
  258. //
  259. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  260. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  261. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  262. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  263. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  264. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  265. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  266. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  267. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  268. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  269. // SUCH DAMAGE.
  270. //
  271. // @(#)types.h 8.3 (Berkeley) 1/5/94
  272. // @(#)ansi.h 8.2 (Berkeley) 1/4/94
  273. // _ALIGN(p) rounds p (pointer or byte index) up to a correctly-aligned
  274. // value for all data types (int, long, ...). The result is an
  275. // unsigned long and must be cast to any desired pointer type.
  276. //
  277. // _ALIGNED_POINTER is a boolean macro that checks whether an address
  278. // is valid to fetch data elements of type t from on this architecture.
  279. // This does not reflect the optimal alignment, just the possibility
  280. // (within reasonable limits).
  281. // 7.18.1.1 Exact-width integer types
  282. type X__int8_t = int8 /* _types.h:61:22 */
  283. type X__uint8_t = uint8 /* _types.h:62:24 */
  284. type X__int16_t = int16 /* _types.h:63:17 */
  285. type X__uint16_t = uint16 /* _types.h:64:25 */
  286. type X__int32_t = int32 /* _types.h:65:15 */
  287. type X__uint32_t = uint32 /* _types.h:66:23 */
  288. type X__int64_t = int64 /* _types.h:67:20 */
  289. type X__uint64_t = uint64 /* _types.h:68:28 */
  290. // 7.18.1.2 Minimum-width integer types
  291. type X__int_least8_t = X__int8_t /* _types.h:71:19 */
  292. type X__uint_least8_t = X__uint8_t /* _types.h:72:20 */
  293. type X__int_least16_t = X__int16_t /* _types.h:73:20 */
  294. type X__uint_least16_t = X__uint16_t /* _types.h:74:21 */
  295. type X__int_least32_t = X__int32_t /* _types.h:75:20 */
  296. type X__uint_least32_t = X__uint32_t /* _types.h:76:21 */
  297. type X__int_least64_t = X__int64_t /* _types.h:77:20 */
  298. type X__uint_least64_t = X__uint64_t /* _types.h:78:21 */
  299. // 7.18.1.3 Fastest minimum-width integer types
  300. type X__int_fast8_t = X__int32_t /* _types.h:81:20 */
  301. type X__uint_fast8_t = X__uint32_t /* _types.h:82:21 */
  302. type X__int_fast16_t = X__int32_t /* _types.h:83:20 */
  303. type X__uint_fast16_t = X__uint32_t /* _types.h:84:21 */
  304. type X__int_fast32_t = X__int32_t /* _types.h:85:20 */
  305. type X__uint_fast32_t = X__uint32_t /* _types.h:86:21 */
  306. type X__int_fast64_t = X__int64_t /* _types.h:87:20 */
  307. type X__uint_fast64_t = X__uint64_t /* _types.h:88:21 */
  308. // 7.18.1.4 Integer types capable of holding object pointers
  309. type X__intptr_t = int32 /* _types.h:103:16 */
  310. type X__uintptr_t = uint32 /* _types.h:104:24 */
  311. // 7.18.1.5 Greatest-width integer types
  312. type X__intmax_t = X__int64_t /* _types.h:107:20 */
  313. type X__uintmax_t = X__uint64_t /* _types.h:108:21 */
  314. // Register size
  315. type X__register_t = int32 /* _types.h:111:16 */
  316. // VM system types
  317. type X__vaddr_t = uint32 /* _types.h:114:24 */
  318. type X__paddr_t = uint32 /* _types.h:115:24 */
  319. type X__vsize_t = uint32 /* _types.h:116:24 */
  320. type X__psize_t = uint32 /* _types.h:117:24 */
  321. // Standard system types
  322. type X__double_t = float64 /* _types.h:120:22 */
  323. type X__float_t = float64 /* _types.h:121:22 */
  324. type X__ptrdiff_t = int32 /* _types.h:122:16 */
  325. type X__size_t = uint32 /* _types.h:123:24 */
  326. type X__ssize_t = int32 /* _types.h:124:16 */
  327. type X__va_list = X__builtin_va_list /* _types.h:126:27 */
  328. // Wide character support types
  329. type X__wchar_t = int32 /* _types.h:133:15 */
  330. type X__wint_t = int32 /* _types.h:135:15 */
  331. type X__rune_t = int32 /* _types.h:136:15 */
  332. type X__wctrans_t = uintptr /* _types.h:137:14 */
  333. type X__wctype_t = uintptr /* _types.h:138:14 */
  334. // $OpenBSD: types.h,v 1.49 2022/08/06 13:31:13 semarie Exp $
  335. // $NetBSD: types.h,v 1.29 1996/11/15 22:48:25 jtc Exp $
  336. // -
  337. // Copyright (c) 1982, 1986, 1991, 1993
  338. // The Regents of the University of California. All rights reserved.
  339. // (c) UNIX System Laboratories, Inc.
  340. // All or some portions of this file are derived from material licensed
  341. // to the University of California by American Telephone and Telegraph
  342. // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  343. // the permission of UNIX System Laboratories, Inc.
  344. //
  345. // Redistribution and use in source and binary forms, with or without
  346. // modification, are permitted provided that the following conditions
  347. // are met:
  348. // 1. Redistributions of source code must retain the above copyright
  349. // notice, this list of conditions and the following disclaimer.
  350. // 2. Redistributions in binary form must reproduce the above copyright
  351. // notice, this list of conditions and the following disclaimer in the
  352. // documentation and/or other materials provided with the distribution.
  353. // 3. Neither the name of the University nor the names of its contributors
  354. // may be used to endorse or promote products derived from this software
  355. // without specific prior written permission.
  356. //
  357. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  358. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  359. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  360. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  361. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  362. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  363. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  364. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  365. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  366. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  367. // SUCH DAMAGE.
  368. //
  369. // @(#)types.h 8.4 (Berkeley) 1/21/94
  370. // $OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  371. // $NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  372. // Copyright (c) 1991, 1993
  373. // The Regents of the University of California. All rights reserved.
  374. //
  375. // This code is derived from software contributed to Berkeley by
  376. // Berkeley Software Design, Inc.
  377. //
  378. // Redistribution and use in source and binary forms, with or without
  379. // modification, are permitted provided that the following conditions
  380. // are met:
  381. // 1. Redistributions of source code must retain the above copyright
  382. // notice, this list of conditions and the following disclaimer.
  383. // 2. Redistributions in binary form must reproduce the above copyright
  384. // notice, this list of conditions and the following disclaimer in the
  385. // documentation and/or other materials provided with the distribution.
  386. // 3. Neither the name of the University nor the names of its contributors
  387. // may be used to endorse or promote products derived from this software
  388. // without specific prior written permission.
  389. //
  390. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  391. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  392. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  393. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  394. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  395. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  396. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  397. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  398. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  399. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  400. // SUCH DAMAGE.
  401. //
  402. // @(#)cdefs.h 8.7 (Berkeley) 1/21/94
  403. // $OpenBSD: endian.h,v 1.25 2014/12/21 04:49:00 guenther Exp $
  404. // -
  405. // Copyright (c) 1997 Niklas Hallqvist. All rights reserved.
  406. //
  407. // Redistribution and use in source and binary forms, with or without
  408. // modification, are permitted provided that the following conditions
  409. // are met:
  410. // 1. Redistributions of source code must retain the above copyright
  411. // notice, this list of conditions and the following disclaimer.
  412. // 2. Redistributions in binary form must reproduce the above copyright
  413. // notice, this list of conditions and the following disclaimer in the
  414. // documentation and/or other materials provided with the distribution.
  415. //
  416. // THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
  417. // IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  418. // OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  419. // IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
  420. // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  421. // NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  422. // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  423. // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  424. // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  425. // THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  426. // Public definitions for little- and big-endian systems.
  427. // This file should be included as <endian.h> in userspace and as
  428. // <sys/endian.h> in the kernel.
  429. //
  430. // System headers that need endian information but that can't or don't
  431. // want to export the public names here should include <sys/_endian.h>
  432. // and use the internal names: _BYTE_ORDER, _*_ENDIAN, etc.
  433. // $OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  434. // $NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  435. // Copyright (c) 1991, 1993
  436. // The Regents of the University of California. All rights reserved.
  437. //
  438. // This code is derived from software contributed to Berkeley by
  439. // Berkeley Software Design, Inc.
  440. //
  441. // Redistribution and use in source and binary forms, with or without
  442. // modification, are permitted provided that the following conditions
  443. // are met:
  444. // 1. Redistributions of source code must retain the above copyright
  445. // notice, this list of conditions and the following disclaimer.
  446. // 2. Redistributions in binary form must reproduce the above copyright
  447. // notice, this list of conditions and the following disclaimer in the
  448. // documentation and/or other materials provided with the distribution.
  449. // 3. Neither the name of the University nor the names of its contributors
  450. // may be used to endorse or promote products derived from this software
  451. // without specific prior written permission.
  452. //
  453. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  454. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  455. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  456. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  457. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  458. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  459. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  460. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  461. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  462. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  463. // SUCH DAMAGE.
  464. //
  465. // @(#)cdefs.h 8.7 (Berkeley) 1/21/94
  466. // $OpenBSD: _endian.h,v 1.8 2018/01/11 23:13:37 dlg Exp $
  467. // -
  468. // Copyright (c) 1997 Niklas Hallqvist. All rights reserved.
  469. //
  470. // Redistribution and use in source and binary forms, with or without
  471. // modification, are permitted provided that the following conditions
  472. // are met:
  473. // 1. Redistributions of source code must retain the above copyright
  474. // notice, this list of conditions and the following disclaimer.
  475. // 2. Redistributions in binary form must reproduce the above copyright
  476. // notice, this list of conditions and the following disclaimer in the
  477. // documentation and/or other materials provided with the distribution.
  478. //
  479. // THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
  480. // IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  481. // OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  482. // IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
  483. // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  484. // NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  485. // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  486. // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  487. // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  488. // THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  489. // Internal endianness macros. This pulls in <machine/endian.h> to
  490. // get the correct setting direction for the platform and sets internal
  491. // ('__' prefix) macros appropriately.
  492. // $OpenBSD: _types.h,v 1.10 2022/08/06 13:31:13 semarie Exp $
  493. // -
  494. // Copyright (c) 1990, 1993
  495. // The Regents of the University of California. All rights reserved.
  496. //
  497. // Redistribution and use in source and binary forms, with or without
  498. // modification, are permitted provided that the following conditions
  499. // are met:
  500. // 1. Redistributions of source code must retain the above copyright
  501. // notice, this list of conditions and the following disclaimer.
  502. // 2. Redistributions in binary form must reproduce the above copyright
  503. // notice, this list of conditions and the following disclaimer in the
  504. // documentation and/or other materials provided with the distribution.
  505. // 3. Neither the name of the University nor the names of its contributors
  506. // may be used to endorse or promote products derived from this software
  507. // without specific prior written permission.
  508. //
  509. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  510. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  511. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  512. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  513. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  514. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  515. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  516. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  517. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  518. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  519. // SUCH DAMAGE.
  520. //
  521. // @(#)types.h 8.3 (Berkeley) 1/5/94
  522. // $OpenBSD: _types.h,v 1.23 2018/03/05 01:15:25 deraadt Exp $
  523. // -
  524. // Copyright (c) 1990, 1993
  525. // The Regents of the University of California. All rights reserved.
  526. //
  527. // Redistribution and use in source and binary forms, with or without
  528. // modification, are permitted provided that the following conditions
  529. // are met:
  530. // 1. Redistributions of source code must retain the above copyright
  531. // notice, this list of conditions and the following disclaimer.
  532. // 2. Redistributions in binary form must reproduce the above copyright
  533. // notice, this list of conditions and the following disclaimer in the
  534. // documentation and/or other materials provided with the distribution.
  535. // 3. Neither the name of the University nor the names of its contributors
  536. // may be used to endorse or promote products derived from this software
  537. // without specific prior written permission.
  538. //
  539. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  540. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  541. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  542. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  543. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  544. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  545. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  546. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  547. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  548. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  549. // SUCH DAMAGE.
  550. //
  551. // @(#)types.h 8.3 (Berkeley) 1/5/94
  552. // @(#)ansi.h 8.2 (Berkeley) 1/4/94
  553. type X__blkcnt_t = X__int64_t /* _types.h:39:19 */ // blocks allocated for file
  554. type X__blksize_t = X__int32_t /* _types.h:40:19 */ // optimal blocksize for I/O
  555. type X__clock_t = X__int64_t /* _types.h:41:19 */ // ticks in CLOCKS_PER_SEC
  556. type X__clockid_t = X__int32_t /* _types.h:42:19 */ // CLOCK_* identifiers
  557. type X__cpuid_t = uint32 /* _types.h:43:23 */ // CPU id
  558. type X__dev_t = X__int32_t /* _types.h:44:19 */ // device number
  559. type X__fixpt_t = X__uint32_t /* _types.h:45:20 */ // fixed point number
  560. type X__fsblkcnt_t = X__uint64_t /* _types.h:46:20 */ // file system block count
  561. type X__fsfilcnt_t = X__uint64_t /* _types.h:47:20 */ // file system file count
  562. type X__gid_t = X__uint32_t /* _types.h:48:20 */ // group id
  563. type X__id_t = X__uint32_t /* _types.h:49:20 */ // may contain pid, uid or gid
  564. type X__in_addr_t = X__uint32_t /* _types.h:50:20 */ // base type for internet address
  565. type X__in_port_t = X__uint16_t /* _types.h:51:20 */ // IP port type
  566. type X__ino_t = X__uint64_t /* _types.h:52:20 */ // inode number
  567. type X__key_t = int32 /* _types.h:53:15 */ // IPC key (for Sys V IPC)
  568. type X__mode_t = X__uint32_t /* _types.h:54:20 */ // permissions
  569. type X__nlink_t = X__uint32_t /* _types.h:55:20 */ // link count
  570. type X__off_t = X__int64_t /* _types.h:56:19 */ // file offset or size
  571. type X__pid_t = X__int32_t /* _types.h:57:19 */ // process id
  572. type X__rlim_t = X__uint64_t /* _types.h:58:20 */ // resource limit
  573. type X__sa_family_t = X__uint8_t /* _types.h:59:19 */ // sockaddr address family type
  574. type X__segsz_t = X__int32_t /* _types.h:60:19 */ // segment size
  575. type X__socklen_t = X__uint32_t /* _types.h:61:20 */ // length type for network syscalls
  576. type X__suseconds_t = int32 /* _types.h:62:15 */ // microseconds (signed)
  577. type X__time_t = X__int64_t /* _types.h:63:19 */ // epoch time
  578. type X__timer_t = X__int32_t /* _types.h:64:19 */ // POSIX timer identifiers
  579. type X__uid_t = X__uint32_t /* _types.h:65:20 */ // user id
  580. type X__useconds_t = X__uint32_t /* _types.h:66:20 */ // microseconds
  581. // mbstate_t is an opaque object to keep conversion state, during multibyte
  582. // stream conversions. The content must not be referenced by user programs.
  583. type X__mbstate_t = struct {
  584. F__ccgo_pad1 [0]uint32
  585. F__mbstate8 [128]int8
  586. } /* _types.h:75:3 */
  587. // Tell sys/endian.h we have MD variants of the swap macros.
  588. // Note that these macros evaluate their arguments several times.
  589. // Public names
  590. // These are specified to be function-like macros to match the spec
  591. // POSIX names
  592. // original BSD names
  593. // these were exposed here before
  594. // ancient stuff
  595. type U_char = uint8 /* types.h:51:23 */
  596. type U_short = uint16 /* types.h:52:24 */
  597. type U_int = uint32 /* types.h:53:22 */
  598. type U_long = uint32 /* types.h:54:23 */
  599. type Unchar = uint8 /* types.h:56:23 */ // Sys V compatibility
  600. type Ushort = uint16 /* types.h:57:24 */ // Sys V compatibility
  601. type Uint = uint32 /* types.h:58:22 */ // Sys V compatibility
  602. type Ulong = uint32 /* types.h:59:23 */ // Sys V compatibility
  603. type Cpuid_t = X__cpuid_t /* types.h:61:19 */ // CPU id
  604. type Register_t = X__register_t /* types.h:62:22 */ // register-sized type
  605. // XXX The exact-width bit types should only be exposed if __BSD_VISIBLE
  606. // but the rest of the includes are not ready for that yet.
  607. type Int8_t = X__int8_t /* types.h:75:19 */
  608. type Uint8_t = X__uint8_t /* types.h:80:20 */
  609. type Int16_t = X__int16_t /* types.h:85:20 */
  610. type Uint16_t = X__uint16_t /* types.h:90:21 */
  611. type Int32_t = X__int32_t /* types.h:95:20 */
  612. type Uint32_t = X__uint32_t /* types.h:100:21 */
  613. type Int64_t = X__int64_t /* types.h:105:20 */
  614. type Uint64_t = X__uint64_t /* types.h:110:21 */
  615. // BSD-style unsigned bits types
  616. type U_int8_t = X__uint8_t /* types.h:114:19 */
  617. type U_int16_t = X__uint16_t /* types.h:115:20 */
  618. type U_int32_t = X__uint32_t /* types.h:116:20 */
  619. type U_int64_t = X__uint64_t /* types.h:117:20 */
  620. // quads, deprecated in favor of 64 bit int types
  621. type Quad_t = X__int64_t /* types.h:120:19 */
  622. type U_quad_t = X__uint64_t /* types.h:121:20 */
  623. // VM system types
  624. type Vaddr_t = X__vaddr_t /* types.h:125:19 */
  625. type Paddr_t = X__paddr_t /* types.h:126:19 */
  626. type Vsize_t = X__vsize_t /* types.h:127:19 */
  627. type Psize_t = X__psize_t /* types.h:128:19 */
  628. // Standard system types
  629. type Blkcnt_t = X__blkcnt_t /* types.h:132:20 */ // blocks allocated for file
  630. type Blksize_t = X__blksize_t /* types.h:133:21 */ // optimal blocksize for I/O
  631. type Caddr_t = uintptr /* types.h:134:14 */ // core address
  632. type Daddr32_t = X__int32_t /* types.h:135:19 */ // 32-bit disk address
  633. type Daddr_t = X__int64_t /* types.h:136:19 */ // 64-bit disk address
  634. type Dev_t = X__dev_t /* types.h:137:18 */ // device number
  635. type Fixpt_t = X__fixpt_t /* types.h:138:19 */ // fixed point number
  636. type Gid_t = X__gid_t /* types.h:139:18 */ // group id
  637. type Id_t = X__id_t /* types.h:140:17 */ // may contain pid, uid or gid
  638. type Ino_t = X__ino_t /* types.h:141:18 */ // inode number
  639. type Key_t = X__key_t /* types.h:142:18 */ // IPC key (for Sys V IPC)
  640. type Mode_t = X__mode_t /* types.h:143:18 */ // permissions
  641. type Nlink_t = X__nlink_t /* types.h:144:19 */ // link count
  642. type Rlim_t = X__rlim_t /* types.h:145:18 */ // resource limit
  643. type Segsz_t = X__segsz_t /* types.h:146:19 */ // segment size
  644. type Uid_t = X__uid_t /* types.h:147:18 */ // user id
  645. type Useconds_t = X__useconds_t /* types.h:148:22 */ // microseconds
  646. type Suseconds_t = X__suseconds_t /* types.h:149:23 */ // microseconds (signed)
  647. type Fsblkcnt_t = X__fsblkcnt_t /* types.h:150:22 */ // file system block count
  648. type Fsfilcnt_t = X__fsfilcnt_t /* types.h:151:22 */ // file system file count
  649. // The following types may be defined in multiple header files.
  650. type Clock_t = X__clock_t /* types.h:158:19 */
  651. type Clockid_t = X__clockid_t /* types.h:163:21 */
  652. type Pid_t = X__pid_t /* types.h:168:18 */
  653. type Ssize_t = X__ssize_t /* types.h:178:19 */
  654. type Time_t = X__time_t /* types.h:183:18 */
  655. type Timer_t = X__timer_t /* types.h:188:19 */
  656. type Off_t = X__off_t /* types.h:193:18 */
  657. type Div_t = struct {
  658. Fquot int32
  659. Frem int32
  660. } /* stdlib.h:59:3 */
  661. type Ldiv_t = struct {
  662. Fquot int32
  663. Frem int32
  664. } /* stdlib.h:64:3 */
  665. type Lldiv_t = struct {
  666. Fquot int64
  667. Frem int64
  668. } /* stdlib.h:70:3 */
  669. type Qdiv_t = struct {
  670. Fquot Quad_t
  671. Frem Quad_t
  672. } /* stdlib.h:77:3 */
  673. var _ int8 /* gen.c:2:13: */