socket_linux_loong64.go 84 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892
  1. // Code generated by 'ccgo sys/socket/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 sys/socket/socket_linux_loong64.go -pkgname socket', DO NOT EDIT.
  2. package socket
  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. AF_ALG = 38 // socket.h:134:1:
  15. AF_APPLETALK = 5 // socket.h:100:1:
  16. AF_ASH = 18 // socket.h:114:1:
  17. AF_ATMPVC = 8 // socket.h:103:1:
  18. AF_ATMSVC = 20 // socket.h:116:1:
  19. AF_AX25 = 3 // socket.h:98:1:
  20. AF_BLUETOOTH = 31 // socket.h:127:1:
  21. AF_BRIDGE = 7 // socket.h:102:1:
  22. AF_CAIF = 37 // socket.h:133:1:
  23. AF_CAN = 29 // socket.h:125:1:
  24. AF_DECnet = 12 // socket.h:107:1:
  25. AF_ECONET = 19 // socket.h:115:1:
  26. AF_FILE = 1 // socket.h:96:1:
  27. AF_IB = 27 // socket.h:123:1:
  28. AF_IEEE802154 = 36 // socket.h:132:1:
  29. AF_INET = 2 // socket.h:97:1:
  30. AF_INET6 = 10 // socket.h:105:1:
  31. AF_IPX = 4 // socket.h:99:1:
  32. AF_IRDA = 23 // socket.h:119:1:
  33. AF_ISDN = 34 // socket.h:130:1:
  34. AF_IUCV = 32 // socket.h:128:1:
  35. AF_KCM = 41 // socket.h:137:1:
  36. AF_KEY = 15 // socket.h:110:1:
  37. AF_LLC = 26 // socket.h:122:1:
  38. AF_LOCAL = 1 // socket.h:94:1:
  39. AF_MAX = 46 // socket.h:142:1:
  40. AF_MCTP = 45 // socket.h:141:1:
  41. AF_MPLS = 28 // socket.h:124:1:
  42. AF_NETBEUI = 13 // socket.h:108:1:
  43. AF_NETLINK = 16 // socket.h:111:1:
  44. AF_NETROM = 6 // socket.h:101:1:
  45. AF_NFC = 39 // socket.h:135:1:
  46. AF_PACKET = 17 // socket.h:113:1:
  47. AF_PHONET = 35 // socket.h:131:1:
  48. AF_PPPOX = 24 // socket.h:120:1:
  49. AF_QIPCRTR = 42 // socket.h:138:1:
  50. AF_RDS = 21 // socket.h:117:1:
  51. AF_ROSE = 11 // socket.h:106:1:
  52. AF_ROUTE = 16 // socket.h:112:1:
  53. AF_RXRPC = 33 // socket.h:129:1:
  54. AF_SECURITY = 14 // socket.h:109:1:
  55. AF_SMC = 43 // socket.h:139:1:
  56. AF_SNA = 22 // socket.h:118:1:
  57. AF_TIPC = 30 // socket.h:126:1:
  58. AF_UNIX = 1 // socket.h:95:1:
  59. AF_UNSPEC = 0 // socket.h:93:1:
  60. AF_VSOCK = 40 // socket.h:136:1:
  61. AF_WANPIPE = 25 // socket.h:121:1:
  62. AF_X25 = 9 // socket.h:104:1:
  63. AF_XDP = 44 // socket.h:140:1:
  64. BIG_ENDIAN = 4321 // endian.h:28:1:
  65. BYTE_ORDER = 1234 // endian.h:30:1:
  66. FD_SETSIZE = 1024 // select.h:73:1:
  67. FIOGETOWN = 0x8903 // sockios.h:8:1:
  68. FIOSETOWN = 0x8901 // sockios.h:6:1:
  69. LITTLE_ENDIAN = 1234 // endian.h:27:1:
  70. PDP_ENDIAN = 3412 // endian.h:29:1:
  71. PF_ALG = 38 // socket.h:82:1:
  72. PF_APPLETALK = 5 // socket.h:48:1:
  73. PF_ASH = 18 // socket.h:62:1:
  74. PF_ATMPVC = 8 // socket.h:51:1:
  75. PF_ATMSVC = 20 // socket.h:64:1:
  76. PF_AX25 = 3 // socket.h:46:1:
  77. PF_BLUETOOTH = 31 // socket.h:75:1:
  78. PF_BRIDGE = 7 // socket.h:50:1:
  79. PF_CAIF = 37 // socket.h:81:1:
  80. PF_CAN = 29 // socket.h:73:1:
  81. PF_DECnet = 12 // socket.h:55:1:
  82. PF_ECONET = 19 // socket.h:63:1:
  83. PF_FILE = 1 // socket.h:44:1:
  84. PF_IB = 27 // socket.h:71:1:
  85. PF_IEEE802154 = 36 // socket.h:80:1:
  86. PF_INET = 2 // socket.h:45:1:
  87. PF_INET6 = 10 // socket.h:53:1:
  88. PF_IPX = 4 // socket.h:47:1:
  89. PF_IRDA = 23 // socket.h:67:1:
  90. PF_ISDN = 34 // socket.h:78:1:
  91. PF_IUCV = 32 // socket.h:76:1:
  92. PF_KCM = 41 // socket.h:85:1:
  93. PF_KEY = 15 // socket.h:58:1:
  94. PF_LLC = 26 // socket.h:70:1:
  95. PF_LOCAL = 1 // socket.h:42:1:
  96. PF_MAX = 46 // socket.h:90:1:
  97. PF_MCTP = 45 // socket.h:89:1:
  98. PF_MPLS = 28 // socket.h:72:1:
  99. PF_NETBEUI = 13 // socket.h:56:1:
  100. PF_NETLINK = 16 // socket.h:59:1:
  101. PF_NETROM = 6 // socket.h:49:1:
  102. PF_NFC = 39 // socket.h:83:1:
  103. PF_PACKET = 17 // socket.h:61:1:
  104. PF_PHONET = 35 // socket.h:79:1:
  105. PF_PPPOX = 24 // socket.h:68:1:
  106. PF_QIPCRTR = 42 // socket.h:86:1:
  107. PF_RDS = 21 // socket.h:65:1:
  108. PF_ROSE = 11 // socket.h:54:1:
  109. PF_ROUTE = 16 // socket.h:60:1:
  110. PF_RXRPC = 33 // socket.h:77:1:
  111. PF_SECURITY = 14 // socket.h:57:1:
  112. PF_SMC = 43 // socket.h:87:1:
  113. PF_SNA = 22 // socket.h:66:1:
  114. PF_TIPC = 30 // socket.h:74:1:
  115. PF_UNIX = 1 // socket.h:43:1:
  116. PF_UNSPEC = 0 // socket.h:41:1:
  117. PF_VSOCK = 40 // socket.h:84:1:
  118. PF_WANPIPE = 25 // socket.h:69:1:
  119. PF_X25 = 9 // socket.h:52:1:
  120. PF_XDP = 44 // socket.h:88:1:
  121. SCM_TIMESTAMP = 29 // socket.h:156:1:
  122. SCM_TIMESTAMPING = 37 // socket.h:158:1:
  123. SCM_TIMESTAMPING_OPT_STATS = 54 // socket.h:90:1:
  124. SCM_TIMESTAMPING_PKTINFO = 58 // socket.h:98:1:
  125. SCM_TIMESTAMPNS = 35 // socket.h:157:1:
  126. SCM_TXTIME = 61 // socket.h:105:1:
  127. SCM_WIFI_STATUS = 41 // socket.h:64:1:
  128. SIOCATMARK = 0x8905 // sockios.h:10:1:
  129. SIOCGPGRP = 0x8904 // sockios.h:9:1:
  130. SIOCGSTAMPNS_OLD = 0x8907 // sockios.h:12:1:
  131. SIOCGSTAMP_OLD = 0x8906 // sockios.h:11:1:
  132. SIOCSPGRP = 0x8902 // sockios.h:7:1:
  133. SOL_AAL = 265 // socket.h:153:1:
  134. SOL_ALG = 279 // socket.h:167:1:
  135. SOL_ATM = 264 // socket.h:152:1:
  136. SOL_BLUETOOTH = 274 // socket.h:162:1:
  137. SOL_CAIF = 278 // socket.h:166:1:
  138. SOL_DCCP = 269 // socket.h:157:1:
  139. SOL_DECNET = 261 // socket.h:149:1:
  140. SOL_IRDA = 266 // socket.h:154:1:
  141. SOL_IUCV = 277 // socket.h:165:1:
  142. SOL_KCM = 281 // socket.h:169:1:
  143. SOL_LLC = 268 // socket.h:156:1:
  144. SOL_MCTP = 285 // socket.h:173:1:
  145. SOL_MPTCP = 284 // socket.h:172:1:
  146. SOL_NETBEUI = 267 // socket.h:155:1:
  147. SOL_NETLINK = 270 // socket.h:158:1:
  148. SOL_NFC = 280 // socket.h:168:1:
  149. SOL_PACKET = 263 // socket.h:151:1:
  150. SOL_PNPIPE = 275 // socket.h:163:1:
  151. SOL_PPPOL2TP = 273 // socket.h:161:1:
  152. SOL_RAW = 255 // socket.h:148:1:
  153. SOL_RDS = 276 // socket.h:164:1:
  154. SOL_RXRPC = 272 // socket.h:160:1:
  155. SOL_SMC = 286 // socket.h:174:1:
  156. SOL_SOCKET = 1 // socket.h:9:1:
  157. SOL_TIPC = 271 // socket.h:159:1:
  158. SOL_TLS = 282 // socket.h:170:1:
  159. SOL_X25 = 262 // socket.h:150:1:
  160. SOL_XDP = 283 // socket.h:171:1:
  161. SOMAXCONN = 4096 // socket.h:177:1:
  162. SO_ACCEPTCONN = 30 // socket.h:51:1:
  163. SO_ATTACH_BPF = 50 // socket.h:82:1:
  164. SO_ATTACH_FILTER = 26 // socket.h:45:1:
  165. SO_ATTACH_REUSEPORT_CBPF = 51 // socket.h:85:1:
  166. SO_ATTACH_REUSEPORT_EBPF = 52 // socket.h:86:1:
  167. SO_BINDTODEVICE = 25 // socket.h:42:1:
  168. SO_BINDTOIFINDEX = 62 // socket.h:107:1:
  169. SO_BPF_EXTENSIONS = 48 // socket.h:78:1:
  170. SO_BROADCAST = 6 // socket.h:16:1:
  171. SO_BSDCOMPAT = 14 // socket.h:26:1:
  172. SO_BUF_LOCK = 72 // socket.h:127:1:
  173. SO_BUSY_POLL = 46 // socket.h:74:1:
  174. SO_BUSY_POLL_BUDGET = 70 // socket.h:123:1:
  175. SO_CNX_ADVICE = 53 // socket.h:88:1:
  176. SO_COOKIE = 57 // socket.h:96:1:
  177. SO_DEBUG = 1 // socket.h:11:1:
  178. SO_DETACH_BPF = 27 // socket.h:83:1:
  179. SO_DETACH_FILTER = 27 // socket.h:46:1:
  180. SO_DETACH_REUSEPORT_BPF = 68 // socket.h:120:1:
  181. SO_DOMAIN = 39 // socket.h:59:1:
  182. SO_DONTROUTE = 5 // socket.h:15:1:
  183. SO_ERROR = 4 // socket.h:14:1:
  184. SO_GET_FILTER = 26 // socket.h:47:1:
  185. SO_INCOMING_CPU = 49 // socket.h:80:1:
  186. SO_INCOMING_NAPI_ID = 56 // socket.h:94:1:
  187. SO_KEEPALIVE = 9 // socket.h:21:1:
  188. SO_LINGER = 13 // socket.h:25:1:
  189. SO_LOCK_FILTER = 44 // socket.h:70:1:
  190. SO_MARK = 36 // socket.h:56:1:
  191. SO_MAX_PACING_RATE = 47 // socket.h:76:1:
  192. SO_MEMINFO = 55 // socket.h:92:1:
  193. SO_NETNS_COOKIE = 71 // socket.h:125:1:
  194. SO_NOFCS = 43 // socket.h:68:1:
  195. SO_NO_CHECK = 11 // socket.h:23:1:
  196. SO_OOBINLINE = 10 // socket.h:22:1:
  197. SO_PASSCRED = 16 // socket.h:29:1:
  198. SO_PASSPIDFD = 76 // socket.h:135:1:
  199. SO_PASSSEC = 34 // socket.h:54:1:
  200. SO_PEEK_OFF = 42 // socket.h:65:1:
  201. SO_PEERCRED = 17 // socket.h:30:1:
  202. SO_PEERGROUPS = 59 // socket.h:100:1:
  203. SO_PEERNAME = 28 // socket.h:49:1:
  204. SO_PEERPIDFD = 77 // socket.h:136:1:
  205. SO_PEERSEC = 31 // socket.h:53:1:
  206. SO_PREFER_BUSY_POLL = 69 // socket.h:122:1:
  207. SO_PRIORITY = 12 // socket.h:24:1:
  208. SO_PROTOCOL = 38 // socket.h:58:1:
  209. SO_RCVBUF = 8 // socket.h:18:1:
  210. SO_RCVBUFFORCE = 33 // socket.h:20:1:
  211. SO_RCVLOWAT = 18 // socket.h:31:1:
  212. SO_RCVMARK = 75 // socket.h:133:1:
  213. SO_RCVTIMEO = 20 // socket.h:145:1:
  214. SO_RCVTIMEO_NEW = 66 // socket.h:117:1:
  215. SO_RCVTIMEO_OLD = 20 // socket.h:33:1:
  216. SO_RESERVE_MEM = 73 // socket.h:129:1:
  217. SO_REUSEADDR = 2 // socket.h:12:1:
  218. SO_REUSEPORT = 15 // socket.h:27:1:
  219. SO_RXQ_OVFL = 40 // socket.h:61:1:
  220. SO_SECURITY_AUTHENTICATION = 22 // socket.h:38:1:
  221. SO_SECURITY_ENCRYPTION_NETWORK = 24 // socket.h:40:1:
  222. SO_SECURITY_ENCRYPTION_TRANSPORT = 23 // socket.h:39:1:
  223. SO_SELECT_ERR_QUEUE = 45 // socket.h:72:1:
  224. SO_SNDBUF = 7 // socket.h:17:1:
  225. SO_SNDBUFFORCE = 32 // socket.h:19:1:
  226. SO_SNDLOWAT = 19 // socket.h:32:1:
  227. SO_SNDTIMEO = 21 // socket.h:146:1:
  228. SO_SNDTIMEO_NEW = 67 // socket.h:118:1:
  229. SO_SNDTIMEO_OLD = 21 // socket.h:34:1:
  230. SO_TIMESTAMP = 29 // socket.h:141:1:
  231. SO_TIMESTAMPING = 37 // socket.h:143:1:
  232. SO_TIMESTAMPING_NEW = 65 // socket.h:115:1:
  233. SO_TIMESTAMPING_OLD = 37 // socket.h:111:1:
  234. SO_TIMESTAMPNS = 35 // socket.h:142:1:
  235. SO_TIMESTAMPNS_NEW = 64 // socket.h:114:1:
  236. SO_TIMESTAMPNS_OLD = 35 // socket.h:110:1:
  237. SO_TIMESTAMP_NEW = 63 // socket.h:113:1:
  238. SO_TIMESTAMP_OLD = 29 // socket.h:109:1:
  239. SO_TXREHASH = 74 // socket.h:131:1:
  240. SO_TXTIME = 61 // socket.h:104:1:
  241. SO_TYPE = 3 // socket.h:13:1:
  242. SO_WIFI_STATUS = 41 // socket.h:63:1:
  243. SO_ZEROCOPY = 60 // socket.h:102:1:
  244. X_ABILP64 = 3 // <predefined>:377:1:
  245. X_ATFILE_SOURCE = 1 // features.h:353:1:
  246. X_BITS_ATOMIC_WIDE_COUNTER_H = 0 // atomic_wide_counter.h:20:1:
  247. X_BITS_BYTESWAP_H = 1 // byteswap.h:24:1:
  248. X_BITS_ENDIANNESS_H = 1 // endianness.h:2:1:
  249. X_BITS_ENDIAN_H = 1 // endian.h:20:1:
  250. X_BITS_PTHREADTYPES_ARCH_H = 1 // pthreadtypes-arch.h:21:1:
  251. X_BITS_PTHREADTYPES_COMMON_H = 1 // pthreadtypes.h:20:1:
  252. X_BITS_SOCKADDR_H = 1 // sockaddr.h:24:1:
  253. X_BITS_STDINT_INTN_H = 1 // stdint-intn.h:20:1:
  254. X_BITS_TIME64_H = 1 // time64.h:24:1:
  255. X_BITS_TYPESIZES_H = 1 // typesizes.h:24:1:
  256. X_BITS_TYPES_H = 1 // types.h:24:1:
  257. X_BITS_UINTN_IDENTITY_H = 1 // uintn-identity.h:24:1:
  258. X_BSD_SIZE_T_ = 0 // stddef.h:193:1:
  259. X_BSD_SIZE_T_DEFINED_ = 0 // stddef.h:196:1:
  260. X_DEFAULT_SOURCE = 1 // features.h:238:1:
  261. X_ENDIAN_H = 1 // endian.h:19:1:
  262. X_FEATURES_H = 1 // features.h:19:1:
  263. X_FILE_OFFSET_BITS = 64 // <builtin>:25:1:
  264. X_GCC_SIZE_T = 0 // stddef.h:200:1:
  265. X_LINUX_POSIX_TYPES_H = 0 // posix_types.h:3:1:
  266. X_LINUX_STDDEF_H = 0 // stddef.h:3:1:
  267. X_LOONGARCH_ARCH = "loongarch64" // <predefined>:214:1:
  268. X_LOONGARCH_ARCH_LOONGARCH64 = 1 // <predefined>:340:1:
  269. X_LOONGARCH_FPSET = 32 // <predefined>:265:1:
  270. X_LOONGARCH_SIM = 3 // <predefined>:233:1:
  271. X_LOONGARCH_SPFPSET = 32 // <predefined>:88:1:
  272. X_LOONGARCH_SZINT = 32 // <predefined>:230:1:
  273. X_LOONGARCH_SZLONG = 64 // <predefined>:388:1:
  274. X_LOONGARCH_SZPTR = 64 // <predefined>:200:1:
  275. X_LOONGARCH_TUNE = "la464" // <predefined>:245:1:
  276. X_LOONGARCH_TUNE_LA464 = 1 // <predefined>:63:1:
  277. X_LP64 = 1 // <predefined>:372:1:
  278. X_POSIX_C_SOURCE = 200809 // features.h:292:1:
  279. X_POSIX_SOURCE = 1 // features.h:290:1:
  280. X_SIZET_ = 0 // stddef.h:201:1:
  281. X_SIZE_T = 0 // stddef.h:187:1:
  282. X_SIZE_T_ = 0 // stddef.h:192:1:
  283. X_SIZE_T_DECLARED = 0 // stddef.h:197:1:
  284. X_SIZE_T_DEFINED = 0 // stddef.h:195:1:
  285. X_SIZE_T_DEFINED_ = 0 // stddef.h:194:1:
  286. X_SS_SIZE = 128 // sockaddr.h:40:1:
  287. X_STDC_PREDEF_H = 1 // <predefined>:223:1:
  288. X_STRUCT_TIMESPEC = 1 // struct_timespec.h:3:1:
  289. X_SYS_CDEFS_H = 1 // cdefs.h:20:1:
  290. X_SYS_SELECT_H = 1 // select.h:22:1:
  291. X_SYS_SIZE_T_H = 0 // stddef.h:188:1:
  292. X_SYS_SOCKET_H = 1 // socket.h:20:1:
  293. X_SYS_TYPES_H = 1 // types.h:23:1:
  294. X_THREAD_MUTEX_INTERNAL_H = 1 // struct_mutex.h:20:1:
  295. X_THREAD_SHARED_TYPES_H = 1 // thread-shared-types.h:20:1:
  296. X_T_SIZE = 0 // stddef.h:190:1:
  297. X_T_SIZE_ = 0 // stddef.h:189:1:
  298. Linux = 1 // <predefined>:308:1:
  299. Unix = 1 // <predefined>:247:1:
  300. )
  301. // Bits in the FLAGS argument to `send', `recv', et al.
  302. const ( /* socket.h:205:1: */
  303. MSG_OOB = 1 // Process out-of-band data.
  304. MSG_PEEK = 2 // Peek at incoming messages.
  305. MSG_DONTROUTE = 4 // Don't use local routing.
  306. MSG_CTRUNC = 8 // Control data lost before delivery.
  307. MSG_PROXY = 16 // Supply or ask second address.
  308. MSG_TRUNC = 32
  309. MSG_DONTWAIT = 64 // Nonblocking IO.
  310. MSG_EOR = 128 // End of record.
  311. MSG_WAITALL = 256 // Wait for a full request.
  312. MSG_FIN = 512
  313. MSG_SYN = 1024
  314. MSG_CONFIRM = 2048 // Confirm path validity.
  315. MSG_RST = 4096
  316. MSG_ERRQUEUE = 8192 // Fetch message from error queue.
  317. MSG_NOSIGNAL = 16384 // Do not generate SIGPIPE.
  318. MSG_MORE = 32768 // Sender will send more.
  319. MSG_WAITFORONE = 65536 // Wait for at least one packet to return.
  320. MSG_BATCH = 262144 // sendmmsg: more messages coming.
  321. MSG_ZEROCOPY = 67108864 // Use user data in kernel path.
  322. MSG_FASTOPEN = 536870912 // Send data in TCP SYN.
  323. MSG_CMSG_CLOEXEC = 1073741824
  324. )
  325. // Socket level message types. This must match the definitions in
  326. //
  327. // <linux/socket.h>.
  328. const ( /* socket.h:363:1: */
  329. SCM_RIGHTS = 1
  330. )
  331. // Get the architecture-dependent definition of enum __socket_type.
  332. // Define enum __socket_type for generic Linux.
  333. // Copyright (C) 1991-2023 Free Software Foundation, Inc.
  334. // This file is part of the GNU C Library.
  335. //
  336. // The GNU C Library is free software; you can redistribute it and/or
  337. // modify it under the terms of the GNU Lesser General Public
  338. // License as published by the Free Software Foundation; either
  339. // version 2.1 of the License, or (at your option) any later version.
  340. //
  341. // The GNU C Library is distributed in the hope that it will be useful,
  342. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  343. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  344. // Lesser General Public License for more details.
  345. //
  346. // You should have received a copy of the GNU Lesser General Public
  347. // License along with the GNU C Library; if not, see
  348. // <https://www.gnu.org/licenses/>.
  349. // Types of sockets.
  350. const ( /* socket_type.h:24:1: */
  351. SOCK_STREAM = 1 // Sequenced, reliable, connection-based
  352. // byte streams.
  353. SOCK_DGRAM = 2 // Connectionless, unreliable datagrams
  354. // of fixed maximum length.
  355. SOCK_RAW = 3 // Raw protocol interface.
  356. SOCK_RDM = 4 // Reliably-delivered messages.
  357. SOCK_SEQPACKET = 5 // Sequenced, reliable, connection-based,
  358. // datagrams of fixed maximum length.
  359. SOCK_DCCP = 6 // Datagram Congestion Control Protocol.
  360. SOCK_PACKET = 10 // Linux specific way of getting packets
  361. // at the dev level. For writing rarp and
  362. // other similar things on the user level.
  363. // Flags to be ORed into the type parameter of socket and socketpair and
  364. // used for the flags parameter of paccept.
  365. SOCK_CLOEXEC = 524288 // Atomically set close-on-exec flag for the
  366. // new descriptor(s).
  367. SOCK_NONBLOCK = 2048
  368. )
  369. // The following constants should be used for the second parameter of
  370. //
  371. // `shutdown'.
  372. const ( /* socket.h:41:1: */
  373. SHUT_RD = 0 // No more receptions.
  374. SHUT_WR = 1 // No more transmissions.
  375. SHUT_RDWR = 2
  376. )
  377. type Ptrdiff_t = int64 /* <builtin>:3:26 */
  378. type Size_t = uint64 /* <builtin>:9:23 */
  379. type Wchar_t = int32 /* <builtin>:15:24 */
  380. type X__int128_t = struct {
  381. Flo int64
  382. Fhi int64
  383. } /* <builtin>:21:43 */ // must match modernc.org/mathutil.Int128
  384. type X__uint128_t = struct {
  385. Flo uint64
  386. Fhi uint64
  387. } /* <builtin>:22:44 */ // must match modernc.org/mathutil.Int128
  388. type X__builtin_va_list = uintptr /* <builtin>:46:14 */
  389. type X__float128 = float64 /* <builtin>:47:21 */
  390. // Wide character type.
  391. // Locale-writers should change this as necessary to
  392. // be big enough to hold unique values not between 0 and 127,
  393. // and not (wchar_t) -1, for each defined multibyte character.
  394. // Define this type if we are doing the whole job,
  395. // or if we want this type in particular.
  396. // A null pointer constant.
  397. // Structure for scatter/gather I/O.
  398. type Iovec = struct {
  399. Fiov_base uintptr
  400. Fiov_len uint64
  401. } /* struct_iovec.h:26:1 */
  402. // Copyright (C) 1989-2023 Free Software Foundation, Inc.
  403. //
  404. // This file is part of GCC.
  405. //
  406. // GCC is free software; you can redistribute it and/or modify
  407. // it under the terms of the GNU General Public License as published by
  408. // the Free Software Foundation; either version 3, or (at your option)
  409. // any later version.
  410. //
  411. // GCC is distributed in the hope that it will be useful,
  412. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  413. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  414. // GNU General Public License for more details.
  415. //
  416. // Under Section 7 of GPL version 3, you are granted additional
  417. // permissions described in the GCC Runtime Library Exception, version
  418. // 3.1, as published by the Free Software Foundation.
  419. //
  420. // You should have received a copy of the GNU General Public License and
  421. // a copy of the GCC Runtime Library Exception along with this program;
  422. // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
  423. // <http://www.gnu.org/licenses/>.
  424. // ISO C Standard: 7.17 Common definitions <stddef.h>
  425. // Any one of these symbols __need_* means that GNU libc
  426. // wants us just to define one data type. So don't define
  427. // the symbols that indicate this file's entire job has been done.
  428. // This avoids lossage on SunOS but only if stdtypes.h comes first.
  429. // There's no way to win with the other order! Sun lossage.
  430. // Sequent's header files use _PTRDIFF_T_ in some conflicting way.
  431. // Just ignore it.
  432. // On VxWorks, <type/vxTypesBase.h> may have defined macros like
  433. // _TYPE_size_t which will typedef size_t. fixincludes patched the
  434. // vxTypesBase.h so that this macro is only defined if _GCC_SIZE_T is
  435. // not defined, and so that defining this macro defines _GCC_SIZE_T.
  436. // If we find that the macros are still defined at this point, we must
  437. // invoke them so that the type is defined as expected.
  438. // In case nobody has defined these types, but we aren't running under
  439. // GCC 2.00, make sure that __PTRDIFF_TYPE__, __SIZE_TYPE__, and
  440. // __WCHAR_TYPE__ have reasonable values. This can happen if the
  441. // parts of GCC is compiled by an older compiler, that actually
  442. // include gstddef.h, such as collect2.
  443. // Signed type of difference of two pointers.
  444. // Define this type if we are doing the whole job,
  445. // or if we want this type in particular.
  446. // Unsigned type of `sizeof' something.
  447. // Define this type if we are doing the whole job,
  448. // or if we want this type in particular.
  449. // Wide character type.
  450. // Locale-writers should change this as necessary to
  451. // be big enough to hold unique values not between 0 and 127,
  452. // and not (wchar_t) -1, for each defined multibyte character.
  453. // Define this type if we are doing the whole job,
  454. // or if we want this type in particular.
  455. // A null pointer constant.
  456. // This operating system-specific header file defines the SOCK_*, PF_*,
  457. // AF_*, MSG_*, SOL_*, and SO_* constants, and the `struct sockaddr',
  458. // `struct msghdr', and `struct linger' types.
  459. // System-specific socket constants and types. Linux version.
  460. // Copyright (C) 1991-2023 Free Software Foundation, Inc.
  461. // This file is part of the GNU C Library.
  462. //
  463. // The GNU C Library is free software; you can redistribute it and/or
  464. // modify it under the terms of the GNU Lesser General Public
  465. // License as published by the Free Software Foundation; either
  466. // version 2.1 of the License, or (at your option) any later version.
  467. //
  468. // The GNU C Library is distributed in the hope that it will be useful,
  469. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  470. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  471. // Lesser General Public License for more details.
  472. //
  473. // You should have received a copy of the GNU Lesser General Public
  474. // License along with the GNU C Library; if not, see
  475. // <https://www.gnu.org/licenses/>.
  476. // Copyright (C) 1989-2023 Free Software Foundation, Inc.
  477. //
  478. // This file is part of GCC.
  479. //
  480. // GCC is free software; you can redistribute it and/or modify
  481. // it under the terms of the GNU General Public License as published by
  482. // the Free Software Foundation; either version 3, or (at your option)
  483. // any later version.
  484. //
  485. // GCC is distributed in the hope that it will be useful,
  486. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  487. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  488. // GNU General Public License for more details.
  489. //
  490. // Under Section 7 of GPL version 3, you are granted additional
  491. // permissions described in the GCC Runtime Library Exception, version
  492. // 3.1, as published by the Free Software Foundation.
  493. //
  494. // You should have received a copy of the GNU General Public License and
  495. // a copy of the GCC Runtime Library Exception along with this program;
  496. // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
  497. // <http://www.gnu.org/licenses/>.
  498. // ISO C Standard: 7.17 Common definitions <stddef.h>
  499. // Any one of these symbols __need_* means that GNU libc
  500. // wants us just to define one data type. So don't define
  501. // the symbols that indicate this file's entire job has been done.
  502. // This avoids lossage on SunOS but only if stdtypes.h comes first.
  503. // There's no way to win with the other order! Sun lossage.
  504. // Sequent's header files use _PTRDIFF_T_ in some conflicting way.
  505. // Just ignore it.
  506. // On VxWorks, <type/vxTypesBase.h> may have defined macros like
  507. // _TYPE_size_t which will typedef size_t. fixincludes patched the
  508. // vxTypesBase.h so that this macro is only defined if _GCC_SIZE_T is
  509. // not defined, and so that defining this macro defines _GCC_SIZE_T.
  510. // If we find that the macros are still defined at this point, we must
  511. // invoke them so that the type is defined as expected.
  512. // In case nobody has defined these types, but we aren't running under
  513. // GCC 2.00, make sure that __PTRDIFF_TYPE__, __SIZE_TYPE__, and
  514. // __WCHAR_TYPE__ have reasonable values. This can happen if the
  515. // parts of GCC is compiled by an older compiler, that actually
  516. // include gstddef.h, such as collect2.
  517. // Signed type of difference of two pointers.
  518. // Define this type if we are doing the whole job,
  519. // or if we want this type in particular.
  520. // Unsigned type of `sizeof' something.
  521. // Define this type if we are doing the whole job,
  522. // or if we want this type in particular.
  523. // Wide character type.
  524. // Locale-writers should change this as necessary to
  525. // be big enough to hold unique values not between 0 and 127,
  526. // and not (wchar_t) -1, for each defined multibyte character.
  527. // Define this type if we are doing the whole job,
  528. // or if we want this type in particular.
  529. // A null pointer constant.
  530. // Copyright (C) 1991-2023 Free Software Foundation, Inc.
  531. // This file is part of the GNU C Library.
  532. //
  533. // The GNU C Library is free software; you can redistribute it and/or
  534. // modify it under the terms of the GNU Lesser General Public
  535. // License as published by the Free Software Foundation; either
  536. // version 2.1 of the License, or (at your option) any later version.
  537. //
  538. // The GNU C Library is distributed in the hope that it will be useful,
  539. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  540. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  541. // Lesser General Public License for more details.
  542. //
  543. // You should have received a copy of the GNU Lesser General Public
  544. // License along with the GNU C Library; if not, see
  545. // <https://www.gnu.org/licenses/>.
  546. // POSIX Standard: 2.6 Primitive System Data Types <sys/types.h>
  547. // Copyright (C) 1991-2023 Free Software Foundation, Inc.
  548. // This file is part of the GNU C Library.
  549. //
  550. // The GNU C Library is free software; you can redistribute it and/or
  551. // modify it under the terms of the GNU Lesser General Public
  552. // License as published by the Free Software Foundation; either
  553. // version 2.1 of the License, or (at your option) any later version.
  554. //
  555. // The GNU C Library is distributed in the hope that it will be useful,
  556. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  557. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  558. // Lesser General Public License for more details.
  559. //
  560. // You should have received a copy of the GNU Lesser General Public
  561. // License along with the GNU C Library; if not, see
  562. // <https://www.gnu.org/licenses/>.
  563. // bits/types.h -- definitions of __*_t types underlying *_t types.
  564. // Copyright (C) 2002-2023 Free Software Foundation, Inc.
  565. // This file is part of the GNU C Library.
  566. //
  567. // The GNU C Library is free software; you can redistribute it and/or
  568. // modify it under the terms of the GNU Lesser General Public
  569. // License as published by the Free Software Foundation; either
  570. // version 2.1 of the License, or (at your option) any later version.
  571. //
  572. // The GNU C Library is distributed in the hope that it will be useful,
  573. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  574. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  575. // Lesser General Public License for more details.
  576. //
  577. // You should have received a copy of the GNU Lesser General Public
  578. // License along with the GNU C Library; if not, see
  579. // <https://www.gnu.org/licenses/>.
  580. // Never include this file directly; use <sys/types.h> instead.
  581. // Copyright (C) 1991-2023 Free Software Foundation, Inc.
  582. // This file is part of the GNU C Library.
  583. //
  584. // The GNU C Library is free software; you can redistribute it and/or
  585. // modify it under the terms of the GNU Lesser General Public
  586. // License as published by the Free Software Foundation; either
  587. // version 2.1 of the License, or (at your option) any later version.
  588. //
  589. // The GNU C Library is distributed in the hope that it will be useful,
  590. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  591. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  592. // Lesser General Public License for more details.
  593. //
  594. // You should have received a copy of the GNU Lesser General Public
  595. // License along with the GNU C Library; if not, see
  596. // <https://www.gnu.org/licenses/>.
  597. // Copyright (C) 1999-2023 Free Software Foundation, Inc.
  598. // This file is part of the GNU C Library.
  599. //
  600. // The GNU C Library is free software; you can redistribute it and/or
  601. // modify it under the terms of the GNU Lesser General Public
  602. // License as published by the Free Software Foundation; either
  603. // version 2.1 of the License, or (at your option) any later version.
  604. //
  605. // The GNU C Library is distributed in the hope that it will be useful,
  606. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  607. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  608. // Lesser General Public License for more details.
  609. //
  610. // You should have received a copy of the GNU Lesser General Public
  611. // License along with the GNU C Library; if not, see
  612. // <https://www.gnu.org/licenses/>.
  613. // Bit size of the time_t type at glibc build time, general case.
  614. // Copyright (C) 2018-2023 Free Software Foundation, Inc.
  615. // This file is part of the GNU C Library.
  616. //
  617. // The GNU C Library is free software; you can redistribute it and/or
  618. // modify it under the terms of the GNU Lesser General Public
  619. // License as published by the Free Software Foundation; either
  620. // version 2.1 of the License, or (at your option) any later version.
  621. //
  622. // The GNU C Library is distributed in the hope that it will be useful,
  623. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  624. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  625. // Lesser General Public License for more details.
  626. //
  627. // You should have received a copy of the GNU Lesser General Public
  628. // License along with the GNU C Library; if not, see
  629. // <https://www.gnu.org/licenses/>.
  630. // Size in bits of the 'time_t' type of the default ABI.
  631. // Convenience types.
  632. type X__u_char = uint8 /* types.h:31:23 */
  633. type X__u_short = uint16 /* types.h:32:28 */
  634. type X__u_int = uint32 /* types.h:33:22 */
  635. type X__u_long = uint64 /* types.h:34:27 */
  636. // Fixed-size types, underlying types depend on word size and compiler.
  637. type X__int8_t = int8 /* types.h:37:21 */
  638. type X__uint8_t = uint8 /* types.h:38:23 */
  639. type X__int16_t = int16 /* types.h:39:26 */
  640. type X__uint16_t = uint16 /* types.h:40:28 */
  641. type X__int32_t = int32 /* types.h:41:20 */
  642. type X__uint32_t = uint32 /* types.h:42:22 */
  643. type X__int64_t = int64 /* types.h:44:25 */
  644. type X__uint64_t = uint64 /* types.h:45:27 */
  645. // Smallest types with at least a given width.
  646. type X__int_least8_t = int8 /* types.h:52:18 */
  647. type X__uint_least8_t = uint8 /* types.h:53:19 */
  648. type X__int_least16_t = int16 /* types.h:54:19 */
  649. type X__uint_least16_t = uint16 /* types.h:55:20 */
  650. type X__int_least32_t = int32 /* types.h:56:19 */
  651. type X__uint_least32_t = uint32 /* types.h:57:20 */
  652. type X__int_least64_t = int64 /* types.h:58:19 */
  653. type X__uint_least64_t = uint64 /* types.h:59:20 */
  654. // quad_t is also 64 bits.
  655. type X__quad_t = int64 /* types.h:63:18 */
  656. type X__u_quad_t = uint64 /* types.h:64:27 */
  657. // Largest integral types.
  658. type X__intmax_t = int64 /* types.h:72:18 */
  659. type X__uintmax_t = uint64 /* types.h:73:27 */
  660. // The machine-dependent file <bits/typesizes.h> defines __*_T_TYPE
  661. // macros for each of the OS types we define below. The definitions
  662. // of those macros must use the following macros for underlying types.
  663. // We define __S<SIZE>_TYPE and __U<SIZE>_TYPE for the signed and unsigned
  664. // variants of each of the following integer types on this machine.
  665. //
  666. // 16 -- "natural" 16-bit type (always short)
  667. // 32 -- "natural" 32-bit type (always int)
  668. // 64 -- "natural" 64-bit type (long or long long)
  669. // LONG32 -- 32-bit type, traditionally long
  670. // QUAD -- 64-bit type, traditionally long long
  671. // WORD -- natural type of __WORDSIZE bits (int or long)
  672. // LONGWORD -- type of __WORDSIZE bits, traditionally long
  673. //
  674. // We distinguish WORD/LONGWORD, 32/LONG32, and 64/QUAD so that the
  675. // conventional uses of `long' or `long long' type modifiers match the
  676. // types we define, even when a less-adorned type would be the same size.
  677. // This matters for (somewhat) portably writing printf/scanf formats for
  678. // these types, where using the appropriate l or ll format modifiers can
  679. // make the typedefs and the formats match up across all GNU platforms. If
  680. // we used `long' when it's 64 bits where `long long' is expected, then the
  681. // compiler would warn about the formats not matching the argument types,
  682. // and the programmer changing them to shut up the compiler would break the
  683. // program's portability.
  684. //
  685. // Here we assume what is presently the case in all the GCC configurations
  686. // we support: long long is always 64 bits, long is always word/address size,
  687. // and int is always 32 bits.
  688. // No need to mark the typedef with __extension__.
  689. // bits/typesizes.h -- underlying types for *_t. For the generic Linux ABI.
  690. // Copyright (C) 2011-2023 Free Software Foundation, Inc.
  691. // This file is part of the GNU C Library.
  692. //
  693. // The GNU C Library is free software; you can redistribute it and/or
  694. // modify it under the terms of the GNU Lesser General Public
  695. // License as published by the Free Software Foundation; either
  696. // version 2.1 of the License, or (at your option) any later version.
  697. //
  698. // The GNU C Library is distributed in the hope that it will be useful,
  699. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  700. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  701. // Lesser General Public License for more details.
  702. //
  703. // You should have received a copy of the GNU Lesser General Public
  704. // License along with the GNU C Library. If not, see
  705. // <https://www.gnu.org/licenses/>.
  706. // See <bits/types.h> for the meaning of these macros. This file exists so
  707. // that <bits/types.h> need not vary across different GNU platforms.
  708. // Tell the libc code that off_t and off64_t are actually the same type
  709. // for all ABI purposes, even if possibly expressed as different base types
  710. // for C type-checking purposes.
  711. // Same for ino_t and ino64_t.
  712. // And for __rlim_t and __rlim64_t.
  713. // And for fsblkcnt_t, fsblkcnt64_t, fsfilcnt_t and fsfilcnt64_t.
  714. // And for getitimer, setitimer and rusage
  715. // Number of descriptors that can fit in an `fd_set'.
  716. // bits/time64.h -- underlying types for __time64_t. Generic version.
  717. // Copyright (C) 2018-2023 Free Software Foundation, Inc.
  718. // This file is part of the GNU C Library.
  719. //
  720. // The GNU C Library is free software; you can redistribute it and/or
  721. // modify it under the terms of the GNU Lesser General Public
  722. // License as published by the Free Software Foundation; either
  723. // version 2.1 of the License, or (at your option) any later version.
  724. //
  725. // The GNU C Library is distributed in the hope that it will be useful,
  726. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  727. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  728. // Lesser General Public License for more details.
  729. //
  730. // You should have received a copy of the GNU Lesser General Public
  731. // License along with the GNU C Library; if not, see
  732. // <https://www.gnu.org/licenses/>.
  733. // Define __TIME64_T_TYPE so that it is always a 64-bit type.
  734. // If we already have 64-bit time type then use it.
  735. type X__dev_t = uint64 /* types.h:145:25 */ // Type of device numbers.
  736. type X__uid_t = uint32 /* types.h:146:25 */ // Type of user identifications.
  737. type X__gid_t = uint32 /* types.h:147:25 */ // Type of group identifications.
  738. type X__ino_t = uint64 /* types.h:148:25 */ // Type of file serial numbers.
  739. type X__ino64_t = uint64 /* types.h:149:27 */ // Type of file serial numbers (LFS).
  740. type X__mode_t = uint32 /* types.h:150:26 */ // Type of file attribute bitmasks.
  741. type X__nlink_t = uint32 /* types.h:151:27 */ // Type of file link counts.
  742. type X__off_t = int64 /* types.h:152:25 */ // Type of file sizes and offsets.
  743. type X__off64_t = int64 /* types.h:153:27 */ // Type of file sizes and offsets (LFS).
  744. type X__pid_t = int32 /* types.h:154:25 */ // Type of process identifications.
  745. type X__fsid_t = struct{ F__val [2]int32 } /* types.h:155:26 */ // Type of file system IDs.
  746. type X__clock_t = int64 /* types.h:156:27 */ // Type of CPU usage counts.
  747. type X__rlim_t = uint64 /* types.h:157:26 */ // Type for resource measurement.
  748. type X__rlim64_t = uint64 /* types.h:158:28 */ // Type for resource measurement (LFS).
  749. type X__id_t = uint32 /* types.h:159:24 */ // General type for IDs.
  750. type X__time_t = int64 /* types.h:160:26 */ // Seconds since the Epoch.
  751. type X__useconds_t = uint32 /* types.h:161:30 */ // Count of microseconds.
  752. type X__suseconds_t = int64 /* types.h:162:31 */ // Signed count of microseconds.
  753. type X__suseconds64_t = int64 /* types.h:163:33 */
  754. type X__daddr_t = int32 /* types.h:165:27 */ // The type of a disk address.
  755. type X__key_t = int32 /* types.h:166:25 */ // Type of an IPC key.
  756. // Clock ID used in clock and timer functions.
  757. type X__clockid_t = int32 /* types.h:169:29 */
  758. // Timer ID returned by `timer_create'.
  759. type X__timer_t = uintptr /* types.h:172:12 */
  760. // Type to represent block size.
  761. type X__blksize_t = int32 /* types.h:175:29 */
  762. // Types from the Large File Support interface.
  763. // Type to count number of disk blocks.
  764. type X__blkcnt_t = int64 /* types.h:180:28 */
  765. type X__blkcnt64_t = int64 /* types.h:181:30 */
  766. // Type to count file system blocks.
  767. type X__fsblkcnt_t = uint64 /* types.h:184:30 */
  768. type X__fsblkcnt64_t = uint64 /* types.h:185:32 */
  769. // Type to count file system nodes.
  770. type X__fsfilcnt_t = uint64 /* types.h:188:30 */
  771. type X__fsfilcnt64_t = uint64 /* types.h:189:32 */
  772. // Type of miscellaneous file system fields.
  773. type X__fsword_t = int64 /* types.h:192:28 */
  774. type X__ssize_t = int64 /* types.h:194:27 */ // Type of a byte count, or error.
  775. // Signed long type used in system calls.
  776. type X__syscall_slong_t = int64 /* types.h:197:33 */
  777. // Unsigned long type used in system calls.
  778. type X__syscall_ulong_t = uint64 /* types.h:199:33 */
  779. // These few don't really vary by system, they always correspond
  780. //
  781. // to one of the other defined types.
  782. type X__loff_t = int64 /* types.h:203:19 */ // Type of file sizes and offsets (LFS).
  783. type X__caddr_t = uintptr /* types.h:204:14 */
  784. // Duplicates info from stdint.h but this is used in unistd.h.
  785. type X__intptr_t = int64 /* types.h:207:25 */
  786. // Duplicate info from sys/socket.h.
  787. type X__socklen_t = uint32 /* types.h:210:23 */
  788. // C99: An integer type that can be accessed as an atomic entity,
  789. //
  790. // even in the presence of asynchronous interrupts.
  791. // It is not currently necessary for this to be machine-specific.
  792. type X__sig_atomic_t = int32 /* types.h:215:13 */
  793. // Seconds since the Epoch, visible to user code when time_t is too
  794. // narrow only for consistency with the old way of widening too-narrow
  795. // types. User code should never use __time64_t.
  796. type U_char = uint8 /* types.h:33:18 */
  797. type U_short = uint16 /* types.h:34:19 */
  798. type U_int = uint32 /* types.h:35:17 */
  799. type U_long = uint64 /* types.h:36:18 */
  800. type Quad_t = int64 /* types.h:37:18 */
  801. type U_quad_t = uint64 /* types.h:38:20 */
  802. type Fsid_t = X__fsid_t /* types.h:39:18 */
  803. type Loff_t = int64 /* types.h:42:18 */
  804. type Ino_t = uint64 /* types.h:49:19 */
  805. type Dev_t = uint64 /* types.h:59:17 */
  806. type Gid_t = uint32 /* types.h:64:17 */
  807. type Mode_t = uint32 /* types.h:69:18 */
  808. type Nlink_t = uint32 /* types.h:74:19 */
  809. type Uid_t = uint32 /* types.h:79:17 */
  810. type Off_t = int64 /* types.h:87:19 */
  811. type Pid_t = int32 /* types.h:97:17 */
  812. type Id_t = uint32 /* types.h:103:16 */
  813. type Ssize_t = int64 /* types.h:108:19 */
  814. type Daddr_t = int32 /* types.h:114:19 */
  815. type Caddr_t = uintptr /* types.h:115:19 */
  816. type Key_t = int32 /* types.h:121:17 */
  817. // bits/types.h -- definitions of __*_t types underlying *_t types.
  818. // Copyright (C) 2002-2023 Free Software Foundation, Inc.
  819. // This file is part of the GNU C Library.
  820. //
  821. // The GNU C Library is free software; you can redistribute it and/or
  822. // modify it under the terms of the GNU Lesser General Public
  823. // License as published by the Free Software Foundation; either
  824. // version 2.1 of the License, or (at your option) any later version.
  825. //
  826. // The GNU C Library is distributed in the hope that it will be useful,
  827. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  828. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  829. // Lesser General Public License for more details.
  830. //
  831. // You should have received a copy of the GNU Lesser General Public
  832. // License along with the GNU C Library; if not, see
  833. // <https://www.gnu.org/licenses/>.
  834. // Never include this file directly; use <sys/types.h> instead.
  835. // Returned by `clock'.
  836. type Clock_t = int64 /* clock_t.h:7:19 */
  837. // bits/types.h -- definitions of __*_t types underlying *_t types.
  838. // Copyright (C) 2002-2023 Free Software Foundation, Inc.
  839. // This file is part of the GNU C Library.
  840. //
  841. // The GNU C Library is free software; you can redistribute it and/or
  842. // modify it under the terms of the GNU Lesser General Public
  843. // License as published by the Free Software Foundation; either
  844. // version 2.1 of the License, or (at your option) any later version.
  845. //
  846. // The GNU C Library is distributed in the hope that it will be useful,
  847. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  848. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  849. // Lesser General Public License for more details.
  850. //
  851. // You should have received a copy of the GNU Lesser General Public
  852. // License along with the GNU C Library; if not, see
  853. // <https://www.gnu.org/licenses/>.
  854. // Never include this file directly; use <sys/types.h> instead.
  855. // Clock ID used in clock and timer functions.
  856. type Clockid_t = int32 /* clockid_t.h:7:21 */
  857. // bits/types.h -- definitions of __*_t types underlying *_t types.
  858. // Copyright (C) 2002-2023 Free Software Foundation, Inc.
  859. // This file is part of the GNU C Library.
  860. //
  861. // The GNU C Library is free software; you can redistribute it and/or
  862. // modify it under the terms of the GNU Lesser General Public
  863. // License as published by the Free Software Foundation; either
  864. // version 2.1 of the License, or (at your option) any later version.
  865. //
  866. // The GNU C Library is distributed in the hope that it will be useful,
  867. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  868. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  869. // Lesser General Public License for more details.
  870. //
  871. // You should have received a copy of the GNU Lesser General Public
  872. // License along with the GNU C Library; if not, see
  873. // <https://www.gnu.org/licenses/>.
  874. // Never include this file directly; use <sys/types.h> instead.
  875. // Returned by `time'.
  876. type Time_t = int64 /* time_t.h:10:18 */
  877. // bits/types.h -- definitions of __*_t types underlying *_t types.
  878. // Copyright (C) 2002-2023 Free Software Foundation, Inc.
  879. // This file is part of the GNU C Library.
  880. //
  881. // The GNU C Library is free software; you can redistribute it and/or
  882. // modify it under the terms of the GNU Lesser General Public
  883. // License as published by the Free Software Foundation; either
  884. // version 2.1 of the License, or (at your option) any later version.
  885. //
  886. // The GNU C Library is distributed in the hope that it will be useful,
  887. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  888. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  889. // Lesser General Public License for more details.
  890. //
  891. // You should have received a copy of the GNU Lesser General Public
  892. // License along with the GNU C Library; if not, see
  893. // <https://www.gnu.org/licenses/>.
  894. // Never include this file directly; use <sys/types.h> instead.
  895. // Timer ID returned by `timer_create'.
  896. type Timer_t = uintptr /* timer_t.h:7:19 */
  897. // Copyright (C) 1989-2023 Free Software Foundation, Inc.
  898. //
  899. // This file is part of GCC.
  900. //
  901. // GCC is free software; you can redistribute it and/or modify
  902. // it under the terms of the GNU General Public License as published by
  903. // the Free Software Foundation; either version 3, or (at your option)
  904. // any later version.
  905. //
  906. // GCC is distributed in the hope that it will be useful,
  907. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  908. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  909. // GNU General Public License for more details.
  910. //
  911. // Under Section 7 of GPL version 3, you are granted additional
  912. // permissions described in the GCC Runtime Library Exception, version
  913. // 3.1, as published by the Free Software Foundation.
  914. //
  915. // You should have received a copy of the GNU General Public License and
  916. // a copy of the GCC Runtime Library Exception along with this program;
  917. // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
  918. // <http://www.gnu.org/licenses/>.
  919. // ISO C Standard: 7.17 Common definitions <stddef.h>
  920. // Any one of these symbols __need_* means that GNU libc
  921. // wants us just to define one data type. So don't define
  922. // the symbols that indicate this file's entire job has been done.
  923. // This avoids lossage on SunOS but only if stdtypes.h comes first.
  924. // There's no way to win with the other order! Sun lossage.
  925. // Sequent's header files use _PTRDIFF_T_ in some conflicting way.
  926. // Just ignore it.
  927. // On VxWorks, <type/vxTypesBase.h> may have defined macros like
  928. // _TYPE_size_t which will typedef size_t. fixincludes patched the
  929. // vxTypesBase.h so that this macro is only defined if _GCC_SIZE_T is
  930. // not defined, and so that defining this macro defines _GCC_SIZE_T.
  931. // If we find that the macros are still defined at this point, we must
  932. // invoke them so that the type is defined as expected.
  933. // In case nobody has defined these types, but we aren't running under
  934. // GCC 2.00, make sure that __PTRDIFF_TYPE__, __SIZE_TYPE__, and
  935. // __WCHAR_TYPE__ have reasonable values. This can happen if the
  936. // parts of GCC is compiled by an older compiler, that actually
  937. // include gstddef.h, such as collect2.
  938. // Signed type of difference of two pointers.
  939. // Define this type if we are doing the whole job,
  940. // or if we want this type in particular.
  941. // Unsigned type of `sizeof' something.
  942. // Define this type if we are doing the whole job,
  943. // or if we want this type in particular.
  944. // Wide character type.
  945. // Locale-writers should change this as necessary to
  946. // be big enough to hold unique values not between 0 and 127,
  947. // and not (wchar_t) -1, for each defined multibyte character.
  948. // Define this type if we are doing the whole job,
  949. // or if we want this type in particular.
  950. // A null pointer constant.
  951. // Old compatibility names for C types.
  952. type Ulong = uint64 /* types.h:148:27 */
  953. type Ushort = uint16 /* types.h:149:28 */
  954. type Uint = uint32 /* types.h:150:22 */
  955. // These size-specific names are used by some of the inet code.
  956. // Define intN_t types.
  957. // Copyright (C) 2017-2023 Free Software Foundation, Inc.
  958. // This file is part of the GNU C Library.
  959. //
  960. // The GNU C Library is free software; you can redistribute it and/or
  961. // modify it under the terms of the GNU Lesser General Public
  962. // License as published by the Free Software Foundation; either
  963. // version 2.1 of the License, or (at your option) any later version.
  964. //
  965. // The GNU C Library is distributed in the hope that it will be useful,
  966. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  967. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  968. // Lesser General Public License for more details.
  969. //
  970. // You should have received a copy of the GNU Lesser General Public
  971. // License along with the GNU C Library; if not, see
  972. // <https://www.gnu.org/licenses/>.
  973. // bits/types.h -- definitions of __*_t types underlying *_t types.
  974. // Copyright (C) 2002-2023 Free Software Foundation, Inc.
  975. // This file is part of the GNU C Library.
  976. //
  977. // The GNU C Library is free software; you can redistribute it and/or
  978. // modify it under the terms of the GNU Lesser General Public
  979. // License as published by the Free Software Foundation; either
  980. // version 2.1 of the License, or (at your option) any later version.
  981. //
  982. // The GNU C Library is distributed in the hope that it will be useful,
  983. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  984. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  985. // Lesser General Public License for more details.
  986. //
  987. // You should have received a copy of the GNU Lesser General Public
  988. // License along with the GNU C Library; if not, see
  989. // <https://www.gnu.org/licenses/>.
  990. // Never include this file directly; use <sys/types.h> instead.
  991. type Int8_t = int8 /* stdint-intn.h:24:18 */
  992. type Int16_t = int16 /* stdint-intn.h:25:19 */
  993. type Int32_t = int32 /* stdint-intn.h:26:19 */
  994. type Int64_t = int64 /* stdint-intn.h:27:19 */
  995. // These were defined by ISO C without the first `_'.
  996. type U_int8_t = uint8 /* types.h:158:19 */
  997. type U_int16_t = uint16 /* types.h:159:20 */
  998. type U_int32_t = uint32 /* types.h:160:20 */
  999. type U_int64_t = uint64 /* types.h:161:20 */
  1000. type Register_t = int32 /* types.h:164:13 */
  1001. // It also defines `fd_set' and the FD_* macros for `select'.
  1002. // `fd_set' type and related macros, and `select'/`pselect' declarations.
  1003. // Copyright (C) 1996-2023 Free Software Foundation, Inc.
  1004. // This file is part of the GNU C Library.
  1005. //
  1006. // The GNU C Library is free software; you can redistribute it and/or
  1007. // modify it under the terms of the GNU Lesser General Public
  1008. // License as published by the Free Software Foundation; either
  1009. // version 2.1 of the License, or (at your option) any later version.
  1010. //
  1011. // The GNU C Library is distributed in the hope that it will be useful,
  1012. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1013. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1014. // Lesser General Public License for more details.
  1015. //
  1016. // You should have received a copy of the GNU Lesser General Public
  1017. // License along with the GNU C Library; if not, see
  1018. // <https://www.gnu.org/licenses/>.
  1019. // POSIX 1003.1g: 6.2 Select from File Descriptor Sets <sys/select.h>
  1020. // Copyright (C) 1991-2023 Free Software Foundation, Inc.
  1021. // This file is part of the GNU C Library.
  1022. //
  1023. // The GNU C Library is free software; you can redistribute it and/or
  1024. // modify it under the terms of the GNU Lesser General Public
  1025. // License as published by the Free Software Foundation; either
  1026. // version 2.1 of the License, or (at your option) any later version.
  1027. //
  1028. // The GNU C Library is distributed in the hope that it will be useful,
  1029. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1030. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1031. // Lesser General Public License for more details.
  1032. //
  1033. // You should have received a copy of the GNU Lesser General Public
  1034. // License along with the GNU C Library; if not, see
  1035. // <https://www.gnu.org/licenses/>.
  1036. // Get definition of needed basic types.
  1037. // bits/types.h -- definitions of __*_t types underlying *_t types.
  1038. // Copyright (C) 2002-2023 Free Software Foundation, Inc.
  1039. // This file is part of the GNU C Library.
  1040. //
  1041. // The GNU C Library is free software; you can redistribute it and/or
  1042. // modify it under the terms of the GNU Lesser General Public
  1043. // License as published by the Free Software Foundation; either
  1044. // version 2.1 of the License, or (at your option) any later version.
  1045. //
  1046. // The GNU C Library is distributed in the hope that it will be useful,
  1047. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1048. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1049. // Lesser General Public License for more details.
  1050. //
  1051. // You should have received a copy of the GNU Lesser General Public
  1052. // License along with the GNU C Library; if not, see
  1053. // <https://www.gnu.org/licenses/>.
  1054. // Never include this file directly; use <sys/types.h> instead.
  1055. // Get __FD_* definitions.
  1056. // Copyright (C) 1997-2023 Free Software Foundation, Inc.
  1057. // This file is part of the GNU C Library.
  1058. //
  1059. // The GNU C Library is free software; you can redistribute it and/or
  1060. // modify it under the terms of the GNU Lesser General Public
  1061. // License as published by the Free Software Foundation; either
  1062. // version 2.1 of the License, or (at your option) any later version.
  1063. //
  1064. // The GNU C Library is distributed in the hope that it will be useful,
  1065. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1066. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1067. // Lesser General Public License for more details.
  1068. //
  1069. // You should have received a copy of the GNU Lesser General Public
  1070. // License along with the GNU C Library; if not, see
  1071. // <https://www.gnu.org/licenses/>.
  1072. // We don't use `memset' because this would require a prototype and
  1073. // the array isn't too big.
  1074. // Get sigset_t.
  1075. type X__sigset_t = struct{ F__val [16]uint64 } /* __sigset_t.h:8:3 */
  1076. // A set of signals to be blocked, unblocked, or waited for.
  1077. type Sigset_t = X__sigset_t /* sigset_t.h:7:20 */
  1078. // Get definition of timer specification structures.
  1079. // bits/types.h -- definitions of __*_t types underlying *_t types.
  1080. // Copyright (C) 2002-2023 Free Software Foundation, Inc.
  1081. // This file is part of the GNU C Library.
  1082. //
  1083. // The GNU C Library is free software; you can redistribute it and/or
  1084. // modify it under the terms of the GNU Lesser General Public
  1085. // License as published by the Free Software Foundation; either
  1086. // version 2.1 of the License, or (at your option) any later version.
  1087. //
  1088. // The GNU C Library is distributed in the hope that it will be useful,
  1089. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1090. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1091. // Lesser General Public License for more details.
  1092. //
  1093. // You should have received a copy of the GNU Lesser General Public
  1094. // License along with the GNU C Library; if not, see
  1095. // <https://www.gnu.org/licenses/>.
  1096. // Never include this file directly; use <sys/types.h> instead.
  1097. // A time value that is accurate to the nearest
  1098. //
  1099. // microsecond but also has a range of years.
  1100. type Timeval = struct {
  1101. Ftv_sec int64
  1102. Ftv_usec int64
  1103. } /* struct_timeval.h:8:1 */
  1104. // NB: Include guard matches what <linux/time.h> uses.
  1105. // bits/types.h -- definitions of __*_t types underlying *_t types.
  1106. // Copyright (C) 2002-2023 Free Software Foundation, Inc.
  1107. // This file is part of the GNU C Library.
  1108. //
  1109. // The GNU C Library is free software; you can redistribute it and/or
  1110. // modify it under the terms of the GNU Lesser General Public
  1111. // License as published by the Free Software Foundation; either
  1112. // version 2.1 of the License, or (at your option) any later version.
  1113. //
  1114. // The GNU C Library is distributed in the hope that it will be useful,
  1115. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1116. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1117. // Lesser General Public License for more details.
  1118. //
  1119. // You should have received a copy of the GNU Lesser General Public
  1120. // License along with the GNU C Library; if not, see
  1121. // <https://www.gnu.org/licenses/>.
  1122. // Never include this file directly; use <sys/types.h> instead.
  1123. // Endian macros for string.h functions
  1124. // Copyright (C) 1992-2023 Free Software Foundation, Inc.
  1125. // This file is part of the GNU C Library.
  1126. //
  1127. // The GNU C Library is free software; you can redistribute it and/or
  1128. // modify it under the terms of the GNU Lesser General Public
  1129. // License as published by the Free Software Foundation; either
  1130. // version 2.1 of the License, or (at your option) any later version.
  1131. //
  1132. // The GNU C Library is distributed in the hope that it will be useful,
  1133. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1134. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1135. // Lesser General Public License for more details.
  1136. //
  1137. // You should have received a copy of the GNU Lesser General Public
  1138. // License along with the GNU C Library; if not, see
  1139. // <http://www.gnu.org/licenses/>.
  1140. // POSIX.1b structure for a time value. This is like a `struct timeval' but
  1141. //
  1142. // has nanoseconds instead of microseconds.
  1143. type Timespec = struct {
  1144. Ftv_sec int64
  1145. Ftv_nsec int64
  1146. } /* struct_timespec.h:11:1 */
  1147. type Suseconds_t = int64 /* select.h:43:23 */
  1148. // The fd_set member is required to be an array of longs.
  1149. type X__fd_mask = int64 /* select.h:49:18 */
  1150. // Some versions of <linux/posix_types.h> define this macros.
  1151. // It's easier to assume 8-bit bytes than to get CHAR_BIT.
  1152. // fd_set for select and pselect.
  1153. type Fd_set = struct{ F__fds_bits [16]int64 } /* select.h:70:5 */
  1154. // Maximum number of file descriptors in `fd_set'.
  1155. // Sometimes the fd_set member is assumed to have this type.
  1156. type Fd_mask = int64 /* select.h:77:19 */
  1157. // Define some inlines helping to catch common problems.
  1158. type Blksize_t = int32 /* types.h:185:21 */
  1159. // Types from the Large File Support interface.
  1160. type Blkcnt_t = int64 /* types.h:205:22 */ // Type to count number of disk blocks.
  1161. type Fsblkcnt_t = uint64 /* types.h:209:24 */ // Type to count file system blocks.
  1162. type Fsfilcnt_t = uint64 /* types.h:213:24 */ // Type to count file system inodes.
  1163. // Now add the thread types.
  1164. // Declaration of common pthread types for all architectures.
  1165. // Copyright (C) 2017-2023 Free Software Foundation, Inc.
  1166. // This file is part of the GNU C Library.
  1167. //
  1168. // The GNU C Library is free software; you can redistribute it and/or
  1169. // modify it under the terms of the GNU Lesser General Public
  1170. // License as published by the Free Software Foundation; either
  1171. // version 2.1 of the License, or (at your option) any later version.
  1172. //
  1173. // The GNU C Library is distributed in the hope that it will be useful,
  1174. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1175. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1176. // Lesser General Public License for more details.
  1177. //
  1178. // You should have received a copy of the GNU Lesser General Public
  1179. // License along with the GNU C Library; if not, see
  1180. // <https://www.gnu.org/licenses/>.
  1181. // For internal mutex and condition variable definitions.
  1182. // Common threading primitives definitions for both POSIX and C11.
  1183. // Copyright (C) 2017-2023 Free Software Foundation, Inc.
  1184. // This file is part of the GNU C Library.
  1185. //
  1186. // The GNU C Library is free software; you can redistribute it and/or
  1187. // modify it under the terms of the GNU Lesser General Public
  1188. // License as published by the Free Software Foundation; either
  1189. // version 2.1 of the License, or (at your option) any later version.
  1190. //
  1191. // The GNU C Library is distributed in the hope that it will be useful,
  1192. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1193. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1194. // Lesser General Public License for more details.
  1195. //
  1196. // You should have received a copy of the GNU Lesser General Public
  1197. // License along with the GNU C Library; if not, see
  1198. // <https://www.gnu.org/licenses/>.
  1199. // Arch-specific definitions. Each architecture must define the following
  1200. // macros to define the expected sizes of pthread data types:
  1201. //
  1202. // __SIZEOF_PTHREAD_ATTR_T - size of pthread_attr_t.
  1203. // __SIZEOF_PTHREAD_MUTEX_T - size of pthread_mutex_t.
  1204. // __SIZEOF_PTHREAD_MUTEXATTR_T - size of pthread_mutexattr_t.
  1205. // __SIZEOF_PTHREAD_COND_T - size of pthread_cond_t.
  1206. // __SIZEOF_PTHREAD_CONDATTR_T - size of pthread_condattr_t.
  1207. // __SIZEOF_PTHREAD_RWLOCK_T - size of pthread_rwlock_t.
  1208. // __SIZEOF_PTHREAD_RWLOCKATTR_T - size of pthread_rwlockattr_t.
  1209. // __SIZEOF_PTHREAD_BARRIER_T - size of pthread_barrier_t.
  1210. // __SIZEOF_PTHREAD_BARRIERATTR_T - size of pthread_barrierattr_t.
  1211. //
  1212. // The additional macro defines any constraint for the lock alignment
  1213. // inside the thread structures:
  1214. //
  1215. // __LOCK_ALIGNMENT - for internal lock/futex usage.
  1216. //
  1217. // Same idea but for the once locking primitive:
  1218. //
  1219. // __ONCE_ALIGNMENT - for pthread_once_t/once_flag definition.
  1220. // Machine-specific pthread type layouts. Generic version.
  1221. // Copyright (C) 2019-2023 Free Software Foundation, Inc.
  1222. //
  1223. // This file is part of the GNU C Library.
  1224. //
  1225. // The GNU C Library is free software; you can redistribute it and/or
  1226. // modify it under the terms of the GNU Lesser General Public
  1227. // License as published by the Free Software Foundation; either
  1228. // version 2.1 of the License, or (at your option) any later version.
  1229. //
  1230. // The GNU C Library is distributed in the hope that it will be useful,
  1231. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1232. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1233. // Lesser General Public License for more details.
  1234. //
  1235. // You should have received a copy of the GNU Lesser General Public
  1236. // License along with the GNU C Library; if not, see
  1237. // <http://www.gnu.org/licenses/>.
  1238. // Copyright (C) 1999-2023 Free Software Foundation, Inc.
  1239. // This file is part of the GNU C Library.
  1240. //
  1241. // The GNU C Library is free software; you can redistribute it and/or
  1242. // modify it under the terms of the GNU Lesser General Public
  1243. // License as published by the Free Software Foundation; either
  1244. // version 2.1 of the License, or (at your option) any later version.
  1245. //
  1246. // The GNU C Library is distributed in the hope that it will be useful,
  1247. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1248. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1249. // Lesser General Public License for more details.
  1250. //
  1251. // You should have received a copy of the GNU Lesser General Public
  1252. // License along with the GNU C Library; if not, see
  1253. // <https://www.gnu.org/licenses/>.
  1254. // Monotonically increasing wide counters (at least 62 bits).
  1255. // Copyright (C) 2016-2023 Free Software Foundation, Inc.
  1256. // This file is part of the GNU C Library.
  1257. //
  1258. // The GNU C Library is free software; you can redistribute it and/or
  1259. // modify it under the terms of the GNU Lesser General Public
  1260. // License as published by the Free Software Foundation; either
  1261. // version 2.1 of the License, or (at your option) any later version.
  1262. //
  1263. // The GNU C Library is distributed in the hope that it will be useful,
  1264. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1265. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1266. // Lesser General Public License for more details.
  1267. //
  1268. // You should have received a copy of the GNU Lesser General Public
  1269. // License along with the GNU C Library; if not, see
  1270. // <https://www.gnu.org/licenses/>.
  1271. // Counter that is monotonically increasing (by less than 2**31 per
  1272. //
  1273. // increment), with a single writer, and an arbitrary number of
  1274. // readers.
  1275. type X__atomic_wide_counter = struct{ F__value64 uint64 } /* atomic_wide_counter.h:33:3 */
  1276. // Common definition of pthread_mutex_t.
  1277. type X__pthread_internal_list = struct {
  1278. F__prev uintptr
  1279. F__next uintptr
  1280. } /* thread-shared-types.h:51:9 */
  1281. // Common definition of pthread_mutex_t.
  1282. type X__pthread_list_t = X__pthread_internal_list /* thread-shared-types.h:55:3 */
  1283. type X__pthread_internal_slist = struct{ F__next uintptr } /* thread-shared-types.h:57:9 */
  1284. type X__pthread_slist_t = X__pthread_internal_slist /* thread-shared-types.h:60:3 */
  1285. // Arch-specific mutex definitions. A generic implementation is provided
  1286. // by sysdeps/nptl/bits/struct_mutex.h. If required, an architecture
  1287. // can override it by defining:
  1288. //
  1289. // 1. struct __pthread_mutex_s (used on both pthread_mutex_t and mtx_t
  1290. // definition). It should contains at least the internal members
  1291. // defined in the generic version.
  1292. //
  1293. // 2. __LOCK_ALIGNMENT for any extra attribute for internal lock used with
  1294. // atomic operations.
  1295. //
  1296. // 3. The macro __PTHREAD_MUTEX_INITIALIZER used for static initialization.
  1297. // It should initialize the mutex internal flag.
  1298. // Default mutex implementation struct definitions.
  1299. // Copyright (C) 2019-2023 Free Software Foundation, Inc.
  1300. // This file is part of the GNU C Library.
  1301. //
  1302. // The GNU C Library is free software; you can redistribute it and/or
  1303. // modify it under the terms of the GNU Lesser General Public
  1304. // License as published by the Free Software Foundation; either
  1305. // version 2.1 of the License, or (at your option) any later version.
  1306. //
  1307. // The GNU C Library is distributed in the hope that it will be useful,
  1308. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1309. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1310. // Lesser General Public License for more details.
  1311. //
  1312. // You should have received a copy of the GNU Lesser General Public
  1313. // License along with the GNU C Library; if not, see
  1314. // <http://www.gnu.org/licenses/>.
  1315. // Generic struct for both POSIX and C11 mutexes. New ports are expected
  1316. // to use the default layout, however architecture can redefine it to
  1317. // add arch-specific extension (such as lock-elision). The struct have
  1318. // a size of 32 bytes on LP32 and 40 bytes on LP64 architectures.
  1319. type X__pthread_mutex_s = struct {
  1320. F__lock int32
  1321. F__count uint32
  1322. F__owner int32
  1323. F__nusers uint32
  1324. F__kind int32
  1325. F__spins int32
  1326. F__list X__pthread_list_t
  1327. } /* struct_mutex.h:27:1 */
  1328. // Arch-sepecific read-write lock definitions. A generic implementation is
  1329. // provided by struct_rwlock.h. If required, an architecture can override it
  1330. // by defining:
  1331. //
  1332. // 1. struct __pthread_rwlock_arch_t (used on pthread_rwlock_t definition).
  1333. // It should contain at least the internal members defined in the
  1334. // generic version.
  1335. //
  1336. // 2. The macro __PTHREAD_RWLOCK_INITIALIZER used for static initialization.
  1337. // It should initialize the rwlock internal type.
  1338. // Default read-write lock implementation struct definitions.
  1339. // Copyright (C) 2019-2023 Free Software Foundation, Inc.
  1340. // This file is part of the GNU C Library.
  1341. //
  1342. // The GNU C Library is free software; you can redistribute it and/or
  1343. // modify it under the terms of the GNU Lesser General Public
  1344. // License as published by the Free Software Foundation; either
  1345. // version 2.1 of the License, or (at your option) any later version.
  1346. //
  1347. // The GNU C Library is distributed in the hope that it will be useful,
  1348. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1349. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1350. // Lesser General Public License for more details.
  1351. //
  1352. // You should have received a copy of the GNU Lesser General Public
  1353. // License along with the GNU C Library; if not, see
  1354. // <http://www.gnu.org/licenses/>.
  1355. // Endian macros for string.h functions
  1356. // Copyright (C) 1992-2023 Free Software Foundation, Inc.
  1357. // This file is part of the GNU C Library.
  1358. //
  1359. // The GNU C Library is free software; you can redistribute it and/or
  1360. // modify it under the terms of the GNU Lesser General Public
  1361. // License as published by the Free Software Foundation; either
  1362. // version 2.1 of the License, or (at your option) any later version.
  1363. //
  1364. // The GNU C Library is distributed in the hope that it will be useful,
  1365. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1366. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1367. // Lesser General Public License for more details.
  1368. //
  1369. // You should have received a copy of the GNU Lesser General Public
  1370. // License along with the GNU C Library; if not, see
  1371. // <http://www.gnu.org/licenses/>.
  1372. // Generic struct for both POSIX read-write lock. New ports are expected
  1373. // to use the default layout, however archictetures can redefine it to add
  1374. // arch-specific extensions (such as lock-elision). The struct have a size
  1375. // of 32 bytes on both LP32 and LP64 architectures.
  1376. type X__pthread_rwlock_arch_t = struct {
  1377. F__readers uint32
  1378. F__writers uint32
  1379. F__wrphase_futex uint32
  1380. F__writers_futex uint32
  1381. F__pad3 uint32
  1382. F__pad4 uint32
  1383. F__flags uint8
  1384. F__shared uint8
  1385. F__pad1 uint8
  1386. F__pad2 uint8
  1387. F__cur_writer int32
  1388. } /* struct_rwlock.h:29:1 */
  1389. // Common definition of pthread_cond_t.
  1390. type X__pthread_cond_s = struct {
  1391. F__wseq X__atomic_wide_counter
  1392. F__g1_start X__atomic_wide_counter
  1393. F__g_refs [2]uint32
  1394. F__g_size [2]uint32
  1395. F__g1_orig_size uint32
  1396. F__wrefs uint32
  1397. F__g_signals [2]uint32
  1398. } /* thread-shared-types.h:94:1 */
  1399. type X__tss_t = uint32 /* thread-shared-types.h:105:22 */
  1400. type X__thrd_t = uint64 /* thread-shared-types.h:106:27 */
  1401. type X__once_flag = struct{ F__data int32 } /* thread-shared-types.h:111:3 */
  1402. // Thread identifiers. The structure of the attribute type is not
  1403. //
  1404. // exposed on purpose.
  1405. type Pthread_t = uint64 /* pthreadtypes.h:27:27 */
  1406. // Data structures for mutex handling. The structure of the attribute
  1407. //
  1408. // type is not exposed on purpose.
  1409. type Pthread_mutexattr_t = struct {
  1410. F__ccgo_pad1 [0]uint32
  1411. F__size [4]int8
  1412. } /* pthreadtypes.h:36:3 */
  1413. // Data structure for condition variable handling. The structure of
  1414. //
  1415. // the attribute type is not exposed on purpose.
  1416. type Pthread_condattr_t = struct {
  1417. F__ccgo_pad1 [0]uint32
  1418. F__size [4]int8
  1419. } /* pthreadtypes.h:45:3 */
  1420. // Keys for thread-specific data
  1421. type Pthread_key_t = uint32 /* pthreadtypes.h:49:22 */
  1422. // Once-only execution
  1423. type Pthread_once_t = int32 /* pthreadtypes.h:53:30 */
  1424. type Pthread_attr_t1 = struct {
  1425. F__ccgo_pad1 [0]uint64
  1426. F__size [56]int8
  1427. } /* pthreadtypes.h:56:1 */
  1428. type Pthread_attr_t = Pthread_attr_t1 /* pthreadtypes.h:62:30 */
  1429. type Pthread_mutex_t = struct{ F__data X__pthread_mutex_s } /* pthreadtypes.h:72:3 */
  1430. type Pthread_cond_t = struct{ F__data X__pthread_cond_s } /* pthreadtypes.h:80:3 */
  1431. // Data structure for reader-writer lock variable handling. The
  1432. //
  1433. // structure of the attribute type is deliberately not exposed.
  1434. type Pthread_rwlock_t = struct {
  1435. F__ccgo_pad1 [0]uint64
  1436. F__data X__pthread_rwlock_arch_t
  1437. F__ccgo_pad2 [24]byte
  1438. } /* pthreadtypes.h:91:3 */
  1439. type Pthread_rwlockattr_t = struct {
  1440. F__ccgo_pad1 [0]uint64
  1441. F__size [8]int8
  1442. } /* pthreadtypes.h:97:3 */
  1443. // POSIX spinlock data type.
  1444. type Pthread_spinlock_t = int32 /* pthreadtypes.h:103:22 */
  1445. // POSIX barriers data type. The structure of the type is
  1446. //
  1447. // deliberately not exposed.
  1448. type Pthread_barrier_t = struct {
  1449. F__ccgo_pad1 [0]uint64
  1450. F__size [32]int8
  1451. } /* pthreadtypes.h:112:3 */
  1452. type Pthread_barrierattr_t = struct {
  1453. F__ccgo_pad1 [0]uint32
  1454. F__size [4]int8
  1455. } /* pthreadtypes.h:118:3 */
  1456. // Type for length arguments in socket calls.
  1457. type Socklen_t = uint32 /* socket.h:33:21 */
  1458. // Protocol families.
  1459. // Address families.
  1460. // Socket level values. Others are defined in the appropriate headers.
  1461. //
  1462. // XXX These definitions also should go into the appropriate headers as
  1463. // far as they are available.
  1464. // Maximum queue length specifiable by listen.
  1465. // Get the definition of the macro to define the common sockaddr members.
  1466. // Definition of struct sockaddr_* common members and sizes, generic version.
  1467. // Copyright (C) 1995-2023 Free Software Foundation, Inc.
  1468. // This file is part of the GNU C Library.
  1469. //
  1470. // The GNU C Library is free software; you can redistribute it and/or
  1471. // modify it under the terms of the GNU Lesser General Public
  1472. // License as published by the Free Software Foundation; either
  1473. // version 2.1 of the License, or (at your option) any later version.
  1474. //
  1475. // The GNU C Library is distributed in the hope that it will be useful,
  1476. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  1477. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  1478. // Lesser General Public License for more details.
  1479. //
  1480. // You should have received a copy of the GNU Lesser General Public
  1481. // License along with the GNU C Library; if not, see
  1482. // <https://www.gnu.org/licenses/>.
  1483. // Never include this file directly; use <sys/socket.h> instead.
  1484. // POSIX.1g specifies this type name for the `sa_family' member.
  1485. type Sa_family_t = uint16 /* sockaddr.h:28:28 */
  1486. // This macro is used to declare the initial common members
  1487. // of the data types used for socket addresses, `struct sockaddr',
  1488. // `struct sockaddr_in', `struct sockaddr_un', etc.
  1489. // Size of struct sockaddr_storage.
  1490. // Structure describing a generic socket address.
  1491. type Sockaddr = struct {
  1492. Fsa_family uint16
  1493. Fsa_data [14]int8
  1494. } /* socket.h:183:1 */
  1495. // Structure large enough to hold any socket address (with the historical
  1496. // exception of AF_UNIX).
  1497. type Sockaddr_storage = struct {
  1498. Fss_family uint16
  1499. F__ss_padding [118]int8
  1500. F__ss_align uint64
  1501. } /* socket.h:196:1 */
  1502. // Structure describing messages sent by
  1503. //
  1504. // `sendmsg' and received by `recvmsg'.
  1505. type Msghdr = struct {
  1506. Fmsg_name uintptr
  1507. Fmsg_namelen uint32
  1508. F__ccgo_pad1 [4]byte
  1509. Fmsg_iov uintptr
  1510. Fmsg_iovlen uint64
  1511. Fmsg_control uintptr
  1512. Fmsg_controllen uint64
  1513. Fmsg_flags int32
  1514. F__ccgo_pad2 [4]byte
  1515. } /* socket.h:262:1 */
  1516. // Structure used for storage of ancillary data object information.
  1517. type Cmsghdr = struct {
  1518. F__ccgo_pad1 [0]uint64
  1519. Fcmsg_len uint64
  1520. Fcmsg_level int32
  1521. Fcmsg_type int32
  1522. } /* socket.h:280:1 */
  1523. // SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note
  1524. // SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note
  1525. // SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note
  1526. // *
  1527. // __struct_group() - Create a mirrored named and anonyomous struct
  1528. //
  1529. // @TAG: The tag name for the named sub-struct (usually empty)
  1530. // @NAME: The identifier name of the mirrored sub-struct
  1531. // @ATTRS: Any struct attributes (usually empty)
  1532. // @MEMBERS: The member declarations for the mirrored structs
  1533. //
  1534. // Used to create an anonymous union of two structs with identical layout
  1535. // and size: one anonymous and one named. The former's members can be used
  1536. // normally without sub-struct naming, and the latter can be used to
  1537. // reason about the start, end, and size of the group of struct members.
  1538. // The named struct can also be explicitly tagged for layer reuse, as well
  1539. // as both having struct attributes appended.
  1540. // *
  1541. // __DECLARE_FLEX_ARRAY() - Declare a flexible array usable in a union
  1542. //
  1543. // @TYPE: The type of each flexible array element
  1544. // @NAME: The name of the flexible array member
  1545. //
  1546. // In order to have a flexible array member in a union or alone in a
  1547. // struct, it needs to be wrapped in an anonymous struct with at least 1
  1548. // named member, but that member can be empty.
  1549. // This allows for 1024 file descriptors: if NR_OPEN is ever grown
  1550. // beyond that you'll have to change this too. But 1024 fd's seem to be
  1551. // enough even for such "real" unices like OSF/1, so hopefully this is
  1552. // one limit that doesn't have to be changed [again].
  1553. //
  1554. // Note that POSIX wants the FD_CLEAR(fd,fdsetp) defines to be in
  1555. // <sys/time.h> (and thus <linux/time.h>) - but this is a more logical
  1556. // place for them. Solved by having dummy defines in <sys/time.h>.
  1557. // This macro may have been defined in <gnu/types.h>. But we always
  1558. // use the one here.
  1559. type X__kernel_fd_set = struct{ Ffds_bits [16]uint64 } /* posix_types.h:27:3 */
  1560. // Type of a signal handler.
  1561. type X__kernel_sighandler_t = uintptr /* posix_types.h:30:14 */
  1562. // Type of a SYSV IPC key.
  1563. type X__kernel_key_t = int32 /* posix_types.h:33:13 */
  1564. type X__kernel_mqd_t = int32 /* posix_types.h:34:13 */
  1565. // SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note
  1566. // SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note
  1567. // In order to keep safe and avoid regression, only unify uapi
  1568. // bitsperlong.h for some archs which are using newer toolchains
  1569. // that have the definitions of __CHAR_BIT__ and __SIZEOF_LONG__.
  1570. // See the following link for more info:
  1571. // https://lore.kernel.org/linux-arch/b9624545-2c80-49a1-ac3c-39264a591f7b@app.fastmail.com/
  1572. // This file is generally used by user-level software, so you need to
  1573. // be a little careful about namespace pollution etc.
  1574. //
  1575. // First the types that are often defined in different ways across
  1576. // architectures, so that you can override them.
  1577. type X__kernel_long_t = int64 /* posix_types.h:15:15 */
  1578. type X__kernel_ulong_t = uint64 /* posix_types.h:16:23 */
  1579. type X__kernel_ino_t = uint64 /* posix_types.h:20:26 */
  1580. type X__kernel_mode_t = uint32 /* posix_types.h:24:22 */
  1581. type X__kernel_pid_t = int32 /* posix_types.h:28:14 */
  1582. type X__kernel_ipc_pid_t = int32 /* posix_types.h:32:14 */
  1583. type X__kernel_uid_t = uint32 /* posix_types.h:36:22 */
  1584. type X__kernel_gid_t = uint32 /* posix_types.h:37:22 */
  1585. type X__kernel_suseconds_t = int64 /* posix_types.h:41:26 */
  1586. type X__kernel_daddr_t = int32 /* posix_types.h:45:14 */
  1587. type X__kernel_uid32_t = uint32 /* posix_types.h:49:22 */
  1588. type X__kernel_gid32_t = uint32 /* posix_types.h:50:22 */
  1589. type X__kernel_old_uid_t = uint32 /* posix_types.h:54:24 */
  1590. type X__kernel_old_gid_t = uint32 /* posix_types.h:55:24 */
  1591. type X__kernel_old_dev_t = uint32 /* posix_types.h:59:22 */
  1592. // Most 32 bit architectures use "unsigned int" size_t,
  1593. // and all 64 bit architectures use "unsigned long" size_t.
  1594. type X__kernel_size_t = uint64 /* posix_types.h:72:26 */
  1595. type X__kernel_ssize_t = int64 /* posix_types.h:73:25 */
  1596. type X__kernel_ptrdiff_t = int64 /* posix_types.h:74:25 */
  1597. type X__kernel_fsid_t = struct{ Fval [2]int32 } /* posix_types.h:81:3 */
  1598. // anything below here should be completely generic
  1599. type X__kernel_off_t = int64 /* posix_types.h:87:25 */
  1600. type X__kernel_loff_t = int64 /* posix_types.h:88:19 */
  1601. type X__kernel_old_time_t = int64 /* posix_types.h:89:25 */
  1602. type X__kernel_time_t = int64 /* posix_types.h:90:25 */
  1603. type X__kernel_time64_t = int64 /* posix_types.h:91:19 */
  1604. type X__kernel_clock_t = int64 /* posix_types.h:92:25 */
  1605. type X__kernel_timer_t = int32 /* posix_types.h:93:14 */
  1606. type X__kernel_clockid_t = int32 /* posix_types.h:94:14 */
  1607. type X__kernel_caddr_t = uintptr /* posix_types.h:95:14 */
  1608. type X__kernel_uid16_t = uint16 /* posix_types.h:96:24 */
  1609. type X__kernel_gid16_t = uint16 /* posix_types.h:97:24 */
  1610. // SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note
  1611. // Socket-level I/O control calls.
  1612. // For setsockopt(2)
  1613. // Security levels - as per NRL IPv6 - don't actually do anything
  1614. // Socket filtering
  1615. // Instruct lower device to use last 4-bytes of skb data as FCS
  1616. // on 64-bit and x32, avoid the ?: operator
  1617. // Structure used to manipulate the SO_LINGER option.
  1618. type Linger = struct {
  1619. Fl_onoff int32
  1620. Fl_linger int32
  1621. } /* socket.h:392:1 */
  1622. // This is the 4.3 BSD `struct sockaddr' format, which is used as wire
  1623. //
  1624. // format in the grotty old 4.3 `talk' protocol.
  1625. type Osockaddr = struct {
  1626. Fsa_family uint16
  1627. Fsa_data [14]uint8
  1628. } /* struct_osockaddr.h:6:1 */
  1629. // Define some macros helping to catch buffer overflows.
  1630. var _ int8 /* gen.c:2:13: */