fts_illumos_amd64.go 125 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038
  1. // Code generated by 'ccgo fts/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 fts/fts_illumos_amd64.go -pkgname fts', DO NOT EDIT.
  2. package fts
  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. CLOCKS_PER_SEC = 1000000 // time_iso.h:78:1:
  15. CLOCK_HIGHRES = 4 // time_impl.h:126:1:
  16. CLOCK_MONOTONIC = 4 // time_impl.h:124:1:
  17. CLOCK_PROCESS_CPUTIME_ID = 5 // time_impl.h:125:1:
  18. CLOCK_PROF = 2 // time_impl.h:127:1:
  19. CLOCK_REALTIME = 3 // time_impl.h:123:1:
  20. CLOCK_THREAD_CPUTIME_ID = 2 // time_impl.h:122:1:
  21. CLOCK_VIRTUAL = 1 // time_impl.h:121:1:
  22. DST_AUST = 2 // time.h:115:1:
  23. DST_AUSTALT = 10 // time.h:123:1:
  24. DST_CAN = 6 // time.h:119:1:
  25. DST_EET = 5 // time.h:118:1:
  26. DST_GB = 7 // time.h:120:1:
  27. DST_MET = 4 // time.h:117:1:
  28. DST_NONE = 0 // time.h:113:1:
  29. DST_RUM = 8 // time.h:121:1:
  30. DST_TUR = 9 // time.h:122:1:
  31. DST_USA = 1 // time.h:114:1:
  32. DST_WET = 3 // time.h:116:1:
  33. FD_SETSIZE = 65536 // select.h:88:1:
  34. FTS_AGAIN = 1 // fts.h:103:1:
  35. FTS_COMFOLLOW = 0x0001 // fts.h:48:1:
  36. FTS_D = 1 // fts.h:84:1:
  37. FTS_DC = 2 // fts.h:85:1:
  38. FTS_DEFAULT = 3 // fts.h:86:1:
  39. FTS_DNR = 4 // fts.h:87:1:
  40. FTS_DONTCHDIR = 0x01 // fts.h:99:1:
  41. FTS_DOT = 5 // fts.h:88:1:
  42. FTS_DP = 6 // fts.h:89:1:
  43. FTS_ERR = 7 // fts.h:90:1:
  44. FTS_F = 8 // fts.h:91:1:
  45. FTS_FOLLOW = 2 // fts.h:104:1:
  46. FTS_INIT = 9 // fts.h:92:1:
  47. FTS_LOGICAL = 0x0002 // fts.h:49:1:
  48. FTS_MAXLEVEL = 0x7fffffff // fts.h:81:1:
  49. FTS_NAMEONLY = 0x1000 // fts.h:57:1:
  50. FTS_NOCHDIR = 0x0004 // fts.h:50:1:
  51. FTS_NOINSTR = 3 // fts.h:105:1:
  52. FTS_NOSTAT = 0x0008 // fts.h:51:1:
  53. FTS_NS = 10 // fts.h:93:1:
  54. FTS_NSOK = 11 // fts.h:94:1:
  55. FTS_OPTIONMASK = 0x00ff // fts.h:55:1:
  56. FTS_PHYSICAL = 0x0010 // fts.h:52:1:
  57. FTS_ROOTLEVEL = 0 // fts.h:80:1:
  58. FTS_ROOTPARENTLEVEL = -1 // fts.h:79:1:
  59. FTS_SEEDOT = 0x0020 // fts.h:53:1:
  60. FTS_SKIP = 4 // fts.h:106:1:
  61. FTS_SL = 12 // fts.h:95:1:
  62. FTS_SLNONE = 13 // fts.h:96:1:
  63. FTS_STOP = 0x2000 // fts.h:58:1:
  64. FTS_SYMFOLLOW = 0x02 // fts.h:100:1:
  65. FTS_XDEV = 0x0040 // fts.h:54:1:
  66. ITIMER_PROF = 2 // time.h:201:1:
  67. ITIMER_REAL = 0 // time.h:199:1:
  68. ITIMER_REALPROF = 3 // time.h:204:1:
  69. ITIMER_VIRTUAL = 1 // time.h:200:1:
  70. MICROSEC = 1000000 // time.h:246:1:
  71. MILLISEC = 1000 // time.h:245:1:
  72. NANOSEC = 1000000000 // time.h:247:1:
  73. NBBY = 8 // select.h:103:1:
  74. P_MYID = -1 // types.h:632:1:
  75. REG_LABEL_BP = 2 // machtypes.h:44:1:
  76. REG_LABEL_MAX = 8 // machtypes.h:51:1:
  77. REG_LABEL_PC = 0 // machtypes.h:42:1:
  78. REG_LABEL_R12 = 4 // machtypes.h:47:1:
  79. REG_LABEL_R13 = 5 // machtypes.h:48:1:
  80. REG_LABEL_R14 = 6 // machtypes.h:49:1:
  81. REG_LABEL_R15 = 7 // machtypes.h:50:1:
  82. REG_LABEL_RBX = 3 // machtypes.h:46:1:
  83. REG_LABEL_SP = 1 // machtypes.h:43:1:
  84. SEC = 1 // time.h:244:1:
  85. S_ENFMT = 1024 // stat.h:426:1:
  86. S_IAMB = 0x1FF // stat.h:406:1:
  87. S_IEXEC = 00100 // stat.h:425:1:
  88. S_IFBLK = 0x6000 // stat.h:414:1:
  89. S_IFCHR = 0x2000 // stat.h:408:1:
  90. S_IFDIR = 0x4000 // stat.h:409:1:
  91. S_IFDOOR = 0xD000 // stat.h:418:1:
  92. S_IFIFO = 0x1000 // stat.h:407:1:
  93. S_IFLNK = 0xA000 // stat.h:416:1:
  94. S_IFMT = 0xF000 // stat.h:405:1:
  95. S_IFNAM = 0x5000 // stat.h:411:1:
  96. S_IFPORT = 0xE000 // stat.h:419:1:
  97. S_IFREG = 0x8000 // stat.h:415:1:
  98. S_IFSOCK = 0xC000 // stat.h:417:1:
  99. S_INSEM = 0x1 // stat.h:412:1:
  100. S_INSHD = 0x2 // stat.h:413:1:
  101. S_IREAD = 00400 // stat.h:423:1:
  102. S_IRGRP = 00040 // stat.h:435:1:
  103. S_IROTH = 00004 // stat.h:439:1:
  104. S_IRUSR = 00400 // stat.h:431:1:
  105. S_IRWXG = 00070 // stat.h:434:1:
  106. S_IRWXO = 00007 // stat.h:438:1:
  107. S_IRWXU = 00700 // stat.h:430:1:
  108. S_ISGID = 0x400 // stat.h:421:1:
  109. S_ISUID = 0x800 // stat.h:420:1:
  110. S_ISVTX = 0x200 // stat.h:422:1:
  111. S_IWGRP = 00020 // stat.h:436:1:
  112. S_IWOTH = 00002 // stat.h:440:1:
  113. S_IWRITE = 00200 // stat.h:424:1:
  114. S_IWUSR = 00200 // stat.h:432:1:
  115. S_IXGRP = 00010 // stat.h:437:1:
  116. S_IXOTH = 00001 // stat.h:441:1:
  117. S_IXUSR = 00100 // stat.h:433:1:
  118. TIMER_ABSTIME = 0x1 // time_impl.h:134:1:
  119. TIMER_RELTIME = 0x0 // time_impl.h:133:1:
  120. TIME_UTC = 0x1 // time.h:306:1:
  121. UTIME_NOW = -1 // stat.h:478:1:
  122. UTIME_OMIT = -2 // stat.h:479:1:
  123. X_ALIGNMENT_REQUIRED = 1 // isa_defs.h:262:1:
  124. X_BIT_FIELDS_LTOH = 0 // isa_defs.h:245:1:
  125. X_BOOL_ALIGNMENT = 1 // isa_defs.h:248:1:
  126. X_CHAR_ALIGNMENT = 1 // isa_defs.h:249:1:
  127. X_CHAR_IS_SIGNED = 0 // isa_defs.h:247:1:
  128. X_CLOCKID_T = 0 // types.h:568:1:
  129. X_CLOCK_T = 0 // types.h:563:1:
  130. X_COND_MAGIC = 0x4356 // types.h:426:1:
  131. X_DMA_USES_PHYSADDR = 0 // isa_defs.h:281:1:
  132. X_DONT_USE_1275_GENERIC_NAMES = 0 // isa_defs.h:287:1:
  133. X_DOUBLE_ALIGNMENT = 8 // isa_defs.h:256:1:
  134. X_DOUBLE_COMPLEX_ALIGNMENT = 8 // isa_defs.h:257:1:
  135. X_DTRACE_VERSION = 1 // feature_tests.h:490:1:
  136. X_FILE_OFFSET_BITS = 64 // <builtin>:25:1:
  137. X_FIRMWARE_NEEDS_FDISK = 0 // isa_defs.h:282:1:
  138. X_FLOAT_ALIGNMENT = 4 // isa_defs.h:252:1:
  139. X_FLOAT_COMPLEX_ALIGNMENT = 4 // isa_defs.h:253:1:
  140. X_FTS_H = 0 // fts.h:31:1:
  141. X_HAVE_CPUID_INSN = 0 // isa_defs.h:288:1:
  142. X_IEEE_754 = 0 // isa_defs.h:246:1:
  143. X_INT64_TYPE = 0 // int_types.h:82:1:
  144. X_INT_ALIGNMENT = 4 // isa_defs.h:251:1:
  145. X_ISO_CPP_14882_1998 = 0 // feature_tests.h:466:1:
  146. X_ISO_C_9899_1999 = 0 // feature_tests.h:472:1:
  147. X_ISO_C_9899_2011 = 0 // feature_tests.h:478:1:
  148. X_ISO_TIME_ISO_H = 0 // time_iso.h:46:1:
  149. X_LARGEFILE64_SOURCE = 1 // feature_tests.h:231:1:
  150. X_LARGEFILE_SOURCE = 1 // feature_tests.h:235:1:
  151. X_LITTLE_ENDIAN = 0 // isa_defs.h:242:1:
  152. X_LOCALE_T = 0 // time.h:291:1:
  153. X_LONGLONG_TYPE = 0 // feature_tests.h:412:1:
  154. X_LONG_ALIGNMENT = 8 // isa_defs.h:254:1:
  155. X_LONG_DOUBLE_ALIGNMENT = 16 // isa_defs.h:258:1:
  156. X_LONG_DOUBLE_COMPLEX_ALIGNMENT = 16 // isa_defs.h:259:1:
  157. X_LONG_LONG_ALIGNMENT = 8 // isa_defs.h:255:1:
  158. X_LONG_LONG_ALIGNMENT_32 = 4 // isa_defs.h:268:1:
  159. X_LONG_LONG_LTOH = 0 // isa_defs.h:244:1:
  160. X_LP64 = 1 // <predefined>:286:1:
  161. X_MAX_ALIGNMENT = 16 // isa_defs.h:261:1:
  162. X_MULTI_DATAMODEL = 0 // isa_defs.h:279:1:
  163. X_MUTEX_MAGIC = 0x4d58 // types.h:424:1:
  164. X_NBBY = 8 // select.h:100:1:
  165. X_NORETURN_KYWD = 0 // feature_tests.h:448:1:
  166. X_OFF_T = 0 // types.h:142:1:
  167. X_POINTER_ALIGNMENT = 8 // isa_defs.h:260:1:
  168. X_PSM_MODULES = 0 // isa_defs.h:284:1:
  169. X_PTRDIFF_T = 0 // types.h:112:1:
  170. X_RESTRICT_KYWD = 0 // feature_tests.h:435:1:
  171. X_RTC_CONFIG = 0 // isa_defs.h:285:1:
  172. X_RWL_MAGIC = 0x5257 // types.h:427:1:
  173. X_SEMA_MAGIC = 0x534d // types.h:425:1:
  174. X_SHORT_ALIGNMENT = 2 // isa_defs.h:250:1:
  175. X_SIGEVENT = 0 // time.h:132:1:
  176. X_SIGSET_T = 0 // select.h:73:1:
  177. X_SIGVAL = 0 // time.h:124:1:
  178. X_SIZE_T = 0 // types.h:540:1:
  179. X_SOFT_HOSTID = 0 // isa_defs.h:286:1:
  180. X_SSIZE_T = 0 // types.h:549:1:
  181. X_STACK_GROWS_DOWNWARD = 0 // isa_defs.h:243:1:
  182. X_STDC_C11 = 0 // feature_tests.h:165:1:
  183. X_STDC_C99 = 0 // feature_tests.h:169:1:
  184. X_ST_FSTYPSZ = 16 // stat.h:60:1:
  185. X_SUNOS_VTOC_16 = 0 // isa_defs.h:280:1:
  186. X_SUSECONDS_T = 0 // types.h:343:1:
  187. X_SYS_CCOMPILE_H = 0 // ccompile.h:32:1:
  188. X_SYS_FEATURE_TESTS_H = 0 // feature_tests.h:41:1:
  189. X_SYS_INT_TYPES_H = 0 // int_types.h:30:1:
  190. X_SYS_ISA_DEFS_H = 0 // isa_defs.h:30:1:
  191. X_SYS_MACHTYPES_H = 0 // machtypes.h:27:1:
  192. X_SYS_NULL_H = 0 // null.h:17:1:
  193. X_SYS_SELECT_H = 0 // select.h:45:1:
  194. X_SYS_STAT_H = 0 // stat.h:32:1:
  195. X_SYS_STAT_IMPL_H = 0 // stat_impl.h:28:1:
  196. X_SYS_TIME_H = 0 // time.h:27:1:
  197. X_SYS_TIME_IMPL_H = 0 // time_impl.h:38:1:
  198. X_SYS_TYPES_H = 0 // types.h:35:1:
  199. X_TIMER_T = 0 // types.h:573:1:
  200. X_TIME_H = 0 // time.h:37:1:
  201. X_TIME_T = 0 // types.h:558:1:
  202. X_UID_T = 0 // types.h:400:1:
  203. X_XOPEN_VERSION = 3 // feature_tests.h:392:1:
  204. Sun = 1 // <predefined>:172:1:
  205. Unix = 1 // <predefined>:175:1:
  206. )
  207. // used for block sizes
  208. // The boolean_t type has had a varied amount of exposure over the years in
  209. // terms of how its enumeration constants have been exposed. In particular, it
  210. // originally used the __XOPEN_OR_POSIX macro to determine whether to prefix the
  211. // B_TRUE and B_FALSE with an underscore. This check never included the
  212. // question of if we were in a strict ANSI C environment or whether extensions
  213. // were defined.
  214. //
  215. // Compilers such as clang started defaulting to always including an
  216. // XOPEN_SOURCE declaration on behalf of users, but also noted __EXTENSIONS__.
  217. // This would lead most software that had used the non-underscore versions to
  218. // need it. As such, we have adjusted the non-strict XOPEN environment to retain
  219. // its old behavior so as to minimize namespace pollution; however, we instead
  220. // include both variants of the definitions in the generally visible version
  221. // allowing software written in either world to hopefully end up in a good
  222. // place.
  223. //
  224. // This isn't perfect, but should hopefully minimize the pain for folks actually
  225. // trying to build software.
  226. const ( /* types.h:215:1: */
  227. B_FALSE = 0
  228. B_TRUE = 1
  229. X_B_FALSE = 0
  230. X_B_TRUE = 1
  231. )
  232. type Ptrdiff_t = int64 /* <builtin>:3:26 */
  233. type Size_t = uint64 /* <builtin>:9:23 */
  234. type Wchar_t = int32 /* <builtin>:15:24 */
  235. type X__int128_t = struct {
  236. Flo int64
  237. Fhi int64
  238. } /* <builtin>:21:43 */ // must match modernc.org/mathutil.Int128
  239. type X__uint128_t = struct {
  240. Flo uint64
  241. Fhi uint64
  242. } /* <builtin>:22:44 */ // must match modernc.org/mathutil.Int128
  243. type X__builtin_va_list = uintptr /* <builtin>:46:14 */
  244. type X__float128 = float64 /* <builtin>:47:21 */
  245. // CDDL HEADER START
  246. //
  247. // The contents of this file are subject to the terms of the
  248. // Common Development and Distribution License (the "License").
  249. // You may not use this file except in compliance with the License.
  250. //
  251. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  252. // or http://www.opensolaris.org/os/licensing.
  253. // See the License for the specific language governing permissions
  254. // and limitations under the License.
  255. //
  256. // When distributing Covered Code, include this CDDL HEADER in each
  257. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  258. // If applicable, add the following below this CDDL HEADER, with the
  259. // fields enclosed by brackets "[]" replaced with your own identifying
  260. // information: Portions Copyright [yyyy] [name of copyright owner]
  261. //
  262. // CDDL HEADER END
  263. // Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T
  264. // All Rights Reserved
  265. // Copyright 2009 Sun Microsystems, Inc. All rights reserved.
  266. // Use is subject to license terms.
  267. //
  268. // Copyright 2013 Nexenta Systems, Inc. All rights reserved.
  269. // Copyright 2016 Joyent, Inc.
  270. // Copyright 2021 Oxide Computer Company
  271. // DO NOT EDIT THIS FILE.
  272. //
  273. // It has been auto-edited by fixincludes from:
  274. //
  275. // "/usr/include/sys/feature_tests.h"
  276. //
  277. // This had to be done to correct non-standard usages in the
  278. // original, manufacturer supplied header file.
  279. // CDDL HEADER START
  280. //
  281. // The contents of this file are subject to the terms of the
  282. // Common Development and Distribution License (the "License").
  283. // You may not use this file except in compliance with the License.
  284. //
  285. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  286. // or http://www.opensolaris.org/os/licensing.
  287. // See the License for the specific language governing permissions
  288. // and limitations under the License.
  289. //
  290. // When distributing Covered Code, include this CDDL HEADER in each
  291. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  292. // If applicable, add the following below this CDDL HEADER, with the
  293. // fields enclosed by brackets "[]" replaced with your own identifying
  294. // information: Portions Copyright [yyyy] [name of copyright owner]
  295. //
  296. // CDDL HEADER END
  297. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  298. // Copyright 2016 Joyent, Inc.
  299. // Copyright 2022 Oxide Computer Company
  300. //
  301. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  302. // Use is subject to license terms.
  303. // CDDL HEADER START
  304. //
  305. // The contents of this file are subject to the terms of the
  306. // Common Development and Distribution License, Version 1.0 only
  307. // (the "License"). You may not use this file except in compliance
  308. // with the License.
  309. //
  310. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  311. // or http://www.opensolaris.org/os/licensing.
  312. // See the License for the specific language governing permissions
  313. // and limitations under the License.
  314. //
  315. // When distributing Covered Code, include this CDDL HEADER in each
  316. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  317. // If applicable, add the following below this CDDL HEADER, with the
  318. // fields enclosed by brackets "[]" replaced with your own identifying
  319. // information: Portions Copyright [yyyy] [name of copyright owner]
  320. //
  321. // CDDL HEADER END
  322. // Copyright 2004 Sun Microsystems, Inc. All rights reserved.
  323. // Use is subject to license terms.
  324. // Copyright 2015 EveryCity Ltd. All rights reserved.
  325. // Copyright 2019 Joyent, Inc.
  326. // This file contains definitions designed to enable different compilers
  327. // to be used harmoniously on Solaris systems.
  328. // Allow for version tests for compiler bugs and features.
  329. // analogous to lint's PRINTFLIKEn
  330. // Handle the kernel printf routines that can take '%b' too
  331. // This one's pretty obvious -- the function never returns
  332. // The function is 'extern inline' and expects GNU C89 behaviour, not C99
  333. // behaviour.
  334. //
  335. // Should only be used on 'extern inline' definitions for GCC.
  336. // The function has control flow such that it may return multiple times (in
  337. // the manner of setjmp or vfork)
  338. // This is an appropriate label for functions that do not
  339. // modify their arguments, e.g. strlen()
  340. // This is a stronger form of __pure__. Can be used for functions
  341. // that do not modify their arguments and don't depend on global
  342. // memory.
  343. // This attribute, attached to a variable, means that the variable is meant to
  344. // be possibly unused. GCC will not produce a warning for this variable.
  345. // Shorthand versions for readability
  346. // In release build, disable warnings about variables
  347. // which are used only for debugging.
  348. // CDDL HEADER START
  349. //
  350. // The contents of this file are subject to the terms of the
  351. // Common Development and Distribution License (the "License").
  352. // You may not use this file except in compliance with the License.
  353. //
  354. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  355. // or http://www.opensolaris.org/os/licensing.
  356. // See the License for the specific language governing permissions
  357. // and limitations under the License.
  358. //
  359. //
  360. // When distributing Covered Code, include this CDDL HEADER in each
  361. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  362. // If applicable, add the following below this CDDL HEADER, with the
  363. // fields enclosed by brackets "[]" replaced with your own identifying
  364. // information: Portions Copyright [yyyy] [name of copyright owner]
  365. //
  366. // CDDL HEADER END
  367. // Copyright 2008 Sun Microsystems, Inc. All rights reserved.
  368. // Use is subject to license terms.
  369. // Copyright 2016 Joyent, Inc.
  370. // This header file serves to group a set of well known defines and to
  371. // set these for each instruction set architecture. These defines may
  372. // be divided into two groups; characteristics of the processor and
  373. // implementation choices for Solaris on a processor.
  374. //
  375. // Processor Characteristics:
  376. //
  377. // _LITTLE_ENDIAN / _BIG_ENDIAN:
  378. // The natural byte order of the processor. A pointer to an int points
  379. // to the least/most significant byte of that int.
  380. //
  381. // _STACK_GROWS_UPWARD / _STACK_GROWS_DOWNWARD:
  382. // The processor specific direction of stack growth. A push onto the
  383. // stack increases/decreases the stack pointer, so it stores data at
  384. // successively higher/lower addresses. (Stackless machines ignored
  385. // without regrets).
  386. //
  387. // _LONG_LONG_HTOL / _LONG_LONG_LTOH:
  388. // A pointer to a long long points to the most/least significant long
  389. // within that long long.
  390. //
  391. // _BIT_FIELDS_HTOL / _BIT_FIELDS_LTOH:
  392. // The C compiler assigns bit fields from the high/low to the low/high end
  393. // of an int (most to least significant vs. least to most significant).
  394. //
  395. // _IEEE_754:
  396. // The processor (or supported implementations of the processor)
  397. // supports the ieee-754 floating point standard. No other floating
  398. // point standards are supported (or significant). Any other supported
  399. // floating point formats are expected to be cased on the ISA processor
  400. // symbol.
  401. //
  402. // _CHAR_IS_UNSIGNED / _CHAR_IS_SIGNED:
  403. // The C Compiler implements objects of type `char' as `unsigned' or
  404. // `signed' respectively. This is really an implementation choice of
  405. // the compiler writer, but it is specified in the ABI and tends to
  406. // be uniform across compilers for an instruction set architecture.
  407. // Hence, it has the properties of a processor characteristic.
  408. //
  409. // _CHAR_ALIGNMENT / _SHORT_ALIGNMENT / _INT_ALIGNMENT / _LONG_ALIGNMENT /
  410. // _LONG_LONG_ALIGNMENT / _DOUBLE_ALIGNMENT / _LONG_DOUBLE_ALIGNMENT /
  411. // _POINTER_ALIGNMENT / _FLOAT_ALIGNMENT:
  412. // The ABI defines alignment requirements of each of the primitive
  413. // object types. Some, if not all, may be hardware requirements as
  414. // well. The values are expressed in "byte-alignment" units.
  415. //
  416. // _MAX_ALIGNMENT:
  417. // The most stringent alignment requirement as specified by the ABI.
  418. // Equal to the maximum of all the above _XXX_ALIGNMENT values.
  419. //
  420. // _MAX_ALIGNMENT_TYPE:
  421. // The name of the C type that has the value descried in _MAX_ALIGNMENT.
  422. //
  423. // _ALIGNMENT_REQUIRED:
  424. // True or false (1 or 0) whether or not the hardware requires the ABI
  425. // alignment.
  426. //
  427. // _LONG_LONG_ALIGNMENT_32
  428. // The 32-bit ABI supported by a 64-bit kernel may have different
  429. // alignment requirements for primitive object types. The value of this
  430. // identifier is expressed in "byte-alignment" units.
  431. //
  432. // _HAVE_CPUID_INSN
  433. // This indicates that the architecture supports the 'cpuid'
  434. // instruction as defined by Intel. (Intel allows other vendors
  435. // to extend the instruction for their own purposes.)
  436. //
  437. //
  438. // Implementation Choices:
  439. //
  440. // _ILP32 / _LP64:
  441. // This specifies the compiler data type implementation as specified in
  442. // the relevant ABI. The choice between these is strongly influenced
  443. // by the underlying hardware, but is not absolutely tied to it.
  444. // Currently only two data type models are supported:
  445. //
  446. // _ILP32:
  447. // Int/Long/Pointer are 32 bits. This is the historical UNIX
  448. // and Solaris implementation. Due to its historical standing,
  449. // this is the default case.
  450. //
  451. // _LP64:
  452. // Long/Pointer are 64 bits, Int is 32 bits. This is the chosen
  453. // implementation for 64-bit ABIs such as SPARC V9.
  454. //
  455. // _I32LPx:
  456. // A compilation environment where 'int' is 32-bit, and
  457. // longs and pointers are simply the same size.
  458. //
  459. // In all cases, Char is 8 bits and Short is 16 bits.
  460. //
  461. // _SUNOS_VTOC_8 / _SUNOS_VTOC_16 / _SVR4_VTOC_16:
  462. // This specifies the form of the disk VTOC (or label):
  463. //
  464. // _SUNOS_VTOC_8:
  465. // This is a VTOC form which is upwardly compatible with the
  466. // SunOS 4.x disk label and allows 8 partitions per disk.
  467. //
  468. // _SUNOS_VTOC_16:
  469. // In this format the incore vtoc image matches the ondisk
  470. // version. It allows 16 slices per disk, and is not
  471. // compatible with the SunOS 4.x disk label.
  472. //
  473. // Note that these are not the only two VTOC forms possible and
  474. // additional forms may be added. One possible form would be the
  475. // SVr4 VTOC form. The symbol for that is reserved now, although
  476. // it is not implemented.
  477. //
  478. // _SVR4_VTOC_16:
  479. // This VTOC form is compatible with the System V Release 4
  480. // VTOC (as implemented on the SVr4 Intel and 3b ports) with
  481. // 16 partitions per disk.
  482. //
  483. //
  484. // _DMA_USES_PHYSADDR / _DMA_USES_VIRTADDR
  485. // This describes the type of addresses used by system DMA:
  486. //
  487. // _DMA_USES_PHYSADDR:
  488. // This type of DMA, used in the x86 implementation,
  489. // requires physical addresses for DMA buffers. The 24-bit
  490. // addresses used by some legacy boards is the source of the
  491. // "low-memory" (<16MB) requirement for some devices using DMA.
  492. //
  493. // _DMA_USES_VIRTADDR:
  494. // This method of DMA allows the use of virtual addresses for
  495. // DMA transfers.
  496. //
  497. // _FIRMWARE_NEEDS_FDISK / _NO_FDISK_PRESENT
  498. // This indicates the presence/absence of an fdisk table.
  499. //
  500. // _FIRMWARE_NEEDS_FDISK
  501. // The fdisk table is required by system firmware. If present,
  502. // it allows a disk to be subdivided into multiple fdisk
  503. // partitions, each of which is equivalent to a separate,
  504. // virtual disk. This enables the co-existence of multiple
  505. // operating systems on a shared hard disk.
  506. //
  507. // _NO_FDISK_PRESENT
  508. // If the fdisk table is absent, it is assumed that the entire
  509. // media is allocated for a single operating system.
  510. //
  511. // _HAVE_TEM_FIRMWARE
  512. // Defined if this architecture has the (fallback) option of
  513. // using prom_* calls for doing I/O if a suitable kernel driver
  514. // is not available to do it.
  515. //
  516. // _DONT_USE_1275_GENERIC_NAMES
  517. // Controls whether or not device tree node names should
  518. // comply with the IEEE 1275 "Generic Names" Recommended
  519. // Practice. With _DONT_USE_GENERIC_NAMES, device-specific
  520. // names identifying the particular device will be used.
  521. //
  522. // __i386_COMPAT
  523. // This indicates whether the i386 ABI is supported as a *non-native*
  524. // mode for the platform. When this symbol is defined:
  525. // - 32-bit xstat-style system calls are enabled
  526. // - 32-bit xmknod-style system calls are enabled
  527. // - 32-bit system calls use i386 sizes -and- alignments
  528. //
  529. // Note that this is NOT defined for the i386 native environment!
  530. //
  531. // __x86
  532. // This is ONLY a synonym for defined(__i386) || defined(__amd64)
  533. // which is useful only insofar as these two architectures share
  534. // common attributes. Analogous to __sparc.
  535. //
  536. // _PSM_MODULES
  537. // This indicates whether or not the implementation uses PSM
  538. // modules for processor support, reading /etc/mach from inside
  539. // the kernel to extract a list.
  540. //
  541. // _RTC_CONFIG
  542. // This indicates whether or not the implementation uses /etc/rtc_config
  543. // to configure the real-time clock in the kernel.
  544. //
  545. // _UNIX_KRTLD
  546. // This indicates that the implementation uses a dynamically
  547. // linked unix + krtld to form the core kernel image at boot
  548. // time, or (in the absence of this symbol) a prelinked kernel image.
  549. //
  550. // _OBP
  551. // This indicates the firmware interface is OBP.
  552. //
  553. // _SOFT_HOSTID
  554. // This indicates that the implementation obtains the hostid
  555. // from the file /etc/hostid, rather than from hardware.
  556. // The following set of definitions characterize Solaris on AMD's
  557. // 64-bit systems.
  558. // Define the appropriate "processor characteristics"
  559. // Different alignment constraints for the i386 ABI in compatibility mode
  560. // Define the appropriate "implementation choices".
  561. // The feature test macro __i386 is generic for all processors implementing
  562. // the Intel 386 instruction set or a superset of it. Specifically, this
  563. // includes all members of the 386, 486, and Pentium family of processors.
  564. // Values of _POSIX_C_SOURCE
  565. //
  566. // undefined not a POSIX compilation
  567. // 1 POSIX.1-1990 compilation
  568. // 2 POSIX.2-1992 compilation
  569. // 199309L POSIX.1b-1993 compilation (Real Time)
  570. // 199506L POSIX.1c-1995 compilation (POSIX Threads)
  571. // 200112L POSIX.1-2001 compilation (Austin Group Revision)
  572. // 200809L POSIX.1-2008 compilation
  573. // The feature test macros __XOPEN_OR_POSIX, _STRICT_STDC, _STRICT_SYMBOLS,
  574. // and _STDC_C99 are Sun implementation specific macros created in order to
  575. // compress common standards specified feature test macros for easier reading.
  576. // These macros should not be used by the application developer as
  577. // unexpected results may occur. Instead, the user should reference
  578. // standards(7) for correct usage of the standards feature test macros.
  579. //
  580. // __XOPEN_OR_POSIX Used in cases where a symbol is defined by both
  581. // X/Open or POSIX or in the negative, when neither
  582. // X/Open or POSIX defines a symbol.
  583. //
  584. // _STRICT_STDC __STDC__ is specified by the C Standards and defined
  585. // by the compiler. For Sun compilers the value of
  586. // __STDC__ is either 1, 0, or not defined based on the
  587. // compilation mode (see cc(1)). When the value of
  588. // __STDC__ is 1 and in the absence of any other feature
  589. // test macros, the namespace available to the application
  590. // is limited to only those symbols defined by the C
  591. // Standard. _STRICT_STDC provides a more readable means
  592. // of identifying symbols defined by the standard, or in
  593. // the negative, symbols that are extensions to the C
  594. // Standard. See additional comments for GNU C differences.
  595. //
  596. // _STDC_C99 __STDC_VERSION__ is specified by the C standards and
  597. // defined by the compiler and indicates the version of
  598. // the C standard. A value of 199901L indicates a
  599. // compiler that complies with ISO/IEC 9899:1999, other-
  600. // wise known as the C99 standard.
  601. //
  602. // _STDC_C11 Like _STDC_C99 except that the value of __STDC_VERSION__
  603. // is 201112L indicating a compiler that compiles with
  604. // ISO/IEC 9899:2011, otherwise known as the C11 standard.
  605. //
  606. // _STRICT_SYMBOLS Used in cases where symbol visibility is restricted
  607. // by the standards, and the user has not explicitly
  608. // relaxed the strictness via __EXTENSIONS__.
  609. // ISO/IEC 9899:1990 and it's revisions, ISO/IEC 9899:1999 and ISO/IEC
  610. // 99899:2011 specify the following predefined macro name:
  611. //
  612. // __STDC__ The integer constant 1, intended to indicate a conforming
  613. // implementation.
  614. //
  615. // Furthermore, a strictly conforming program shall use only those features
  616. // of the language and library specified in these standards. A conforming
  617. // implementation shall accept any strictly conforming program.
  618. //
  619. // Based on these requirements, Sun's C compiler defines __STDC__ to 1 for
  620. // strictly conforming environments and __STDC__ to 0 for environments that
  621. // use ANSI C semantics but allow extensions to the C standard. For non-ANSI
  622. // C semantics, Sun's C compiler does not define __STDC__.
  623. //
  624. // The GNU C project interpretation is that __STDC__ should always be defined
  625. // to 1 for compilation modes that accept ANSI C syntax regardless of whether
  626. // or not extensions to the C standard are used. Violations of conforming
  627. // behavior are conditionally flagged as warnings via the use of the
  628. // -pedantic option. In addition to defining __STDC__ to 1, the GNU C
  629. // compiler also defines __STRICT_ANSI__ as a means of specifying strictly
  630. // conforming environments using the -ansi or -std=<standard> options.
  631. //
  632. // In the absence of any other compiler options, Sun and GNU set the value
  633. // of __STDC__ as follows when using the following options:
  634. //
  635. // Value of __STDC__ __STRICT_ANSI__
  636. //
  637. // cc -Xa (default) 0 undefined
  638. // cc -Xt (transitional) 0 undefined
  639. // cc -Xc (strictly conforming) 1 undefined
  640. // cc -Xs (K&R C) undefined undefined
  641. //
  642. // gcc (default) 1 undefined
  643. // gcc -ansi, -std={c89, c99,...) 1 defined
  644. // gcc -traditional (K&R) undefined undefined
  645. //
  646. // The default compilation modes for Sun C compilers versus GNU C compilers
  647. // results in a differing value for __STDC__ which results in a more
  648. // restricted namespace when using Sun compilers. To allow both GNU and Sun
  649. // interpretations to peacefully co-exist, we use the following Sun
  650. // implementation _STRICT_STDC_ macro:
  651. // Compiler complies with ISO/IEC 9899:1999 or ISO/IEC 9989:2011
  652. // Use strict symbol visibility.
  653. // This is a variant of _STRICT_SYMBOLS that is meant to cover headers that are
  654. // governed by POSIX, but have not been governed by ISO C. One can go two ways
  655. // on what should happen if an application actively includes (not transitively)
  656. // a header that isn't part of the ISO C spec, we opt to say that if someone has
  657. // gone out of there way then they're doing it for a reason and that is an act
  658. // of non-compliance and therefore it's not up to us to hide away every symbol.
  659. //
  660. // In general, prefer using _STRICT_SYMBOLS, but this is here in particular for
  661. // cases where in the past we have only used a POSIX related check and we don't
  662. // wish to make something stricter. Often applications are relying on the
  663. // ability to, or more realistically unwittingly, have _STRICT_STDC declared and
  664. // still use these interfaces.
  665. // Large file interfaces:
  666. //
  667. // _LARGEFILE_SOURCE
  668. // 1 large file-related additions to POSIX
  669. // interfaces requested (fseeko, etc.)
  670. // _LARGEFILE64_SOURCE
  671. // 1 transitional large-file-related interfaces
  672. // requested (seek64, stat64, etc.)
  673. //
  674. // The corresponding announcement macros are respectively:
  675. // _LFS_LARGEFILE
  676. // _LFS64_LARGEFILE
  677. // (These are set in <unistd.h>.)
  678. //
  679. // Requesting _LARGEFILE64_SOURCE implies requesting _LARGEFILE_SOURCE as
  680. // well.
  681. //
  682. // The large file interfaces are made visible regardless of the initial values
  683. // of the feature test macros under certain circumstances:
  684. // - If no explicit standards-conforming environment is requested (neither
  685. // of _POSIX_SOURCE nor _XOPEN_SOURCE is defined and the value of
  686. // __STDC__ does not imply standards conformance).
  687. // - Extended system interfaces are explicitly requested (__EXTENSIONS__
  688. // is defined).
  689. // - Access to in-kernel interfaces is requested (_KERNEL or _KMEMUSER is
  690. // defined). (Note that this dependency is an artifact of the current
  691. // kernel implementation and may change in future releases.)
  692. // Large file compilation environment control:
  693. //
  694. // The setting of _FILE_OFFSET_BITS controls the size of various file-related
  695. // types and governs the mapping between file-related source function symbol
  696. // names and the corresponding binary entry points.
  697. //
  698. // In the 32-bit environment, the default value is 32; if not set, set it to
  699. // the default here, to simplify tests in other headers.
  700. //
  701. // In the 64-bit compilation environment, the only value allowed is 64.
  702. // Use of _XOPEN_SOURCE
  703. //
  704. // The following X/Open specifications are supported:
  705. //
  706. // X/Open Portability Guide, Issue 3 (XPG3)
  707. // X/Open CAE Specification, Issue 4 (XPG4)
  708. // X/Open CAE Specification, Issue 4, Version 2 (XPG4v2)
  709. // X/Open CAE Specification, Issue 5 (XPG5)
  710. // Open Group Technical Standard, Issue 6 (XPG6), also referred to as
  711. // IEEE Std. 1003.1-2001 and ISO/IEC 9945:2002.
  712. // Open Group Technical Standard, Issue 7 (XPG7), also referred to as
  713. // IEEE Std. 1003.1-2008 and ISO/IEC 9945:2009.
  714. //
  715. // XPG4v2 is also referred to as UNIX 95 (SUS or SUSv1).
  716. // XPG5 is also referred to as UNIX 98 or the Single Unix Specification,
  717. // Version 2 (SUSv2)
  718. // XPG6 is the result of a merge of the X/Open and POSIX specifications
  719. // and as such is also referred to as IEEE Std. 1003.1-2001 in
  720. // addition to UNIX 03 and SUSv3.
  721. // XPG7 is also referred to as UNIX 08 and SUSv4.
  722. //
  723. // When writing a conforming X/Open application, as per the specification
  724. // requirements, the appropriate feature test macros must be defined at
  725. // compile time. These are as follows. For more info, see standards(7).
  726. //
  727. // Feature Test Macro Specification
  728. // ------------------------------------------------ -------------
  729. // _XOPEN_SOURCE XPG3
  730. // _XOPEN_SOURCE && _XOPEN_VERSION = 4 XPG4
  731. // _XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED = 1 XPG4v2
  732. // _XOPEN_SOURCE = 500 XPG5
  733. // _XOPEN_SOURCE = 600 (or POSIX_C_SOURCE=200112L) XPG6
  734. // _XOPEN_SOURCE = 700 (or POSIX_C_SOURCE=200809L) XPG7
  735. //
  736. // In order to simplify the guards within the headers, the following
  737. // implementation private test macros have been created. Applications
  738. // must NOT use these private test macros as unexpected results will
  739. // occur.
  740. //
  741. // Note that in general, the use of these private macros is cumulative.
  742. // For example, the use of _XPG3 with no other restrictions on the X/Open
  743. // namespace will make the symbols visible for XPG3 through XPG6
  744. // compilation environments. The use of _XPG4_2 with no other X/Open
  745. // namespace restrictions indicates that the symbols were introduced in
  746. // XPG4v2 and are therefore visible for XPG4v2 through XPG6 compilation
  747. // environments, but not for XPG3 or XPG4 compilation environments.
  748. //
  749. // _XPG3 X/Open Portability Guide, Issue 3 (XPG3)
  750. // _XPG4 X/Open CAE Specification, Issue 4 (XPG4)
  751. // _XPG4_2 X/Open CAE Specification, Issue 4, Version 2 (XPG4v2/UNIX 95/SUS)
  752. // _XPG5 X/Open CAE Specification, Issue 5 (XPG5/UNIX 98/SUSv2)
  753. // _XPG6 Open Group Technical Standard, Issue 6 (XPG6/UNIX 03/SUSv3)
  754. // _XPG7 Open Group Technical Standard, Issue 7 (XPG7/UNIX 08/SUSv4)
  755. // X/Open Portability Guide, Issue 3
  756. // _XOPEN_VERSION is defined by the X/Open specifications and is not
  757. // normally defined by the application, except in the case of an XPG4
  758. // application. On the implementation side, _XOPEN_VERSION defined with
  759. // the value of 3 indicates an XPG3 application. _XOPEN_VERSION defined
  760. // with the value of 4 indicates an XPG4 or XPG4v2 (UNIX 95) application.
  761. // _XOPEN_VERSION defined with a value of 500 indicates an XPG5 (UNIX 98)
  762. // application and with a value of 600 indicates an XPG6 (UNIX 03)
  763. // application and with a value of 700 indicates an XPG7 (UNIX 08).
  764. // The appropriate version is determined by the use of the
  765. // feature test macros described earlier. The value of _XOPEN_VERSION
  766. // defaults to 3 otherwise indicating support for XPG3 applications.
  767. // ANSI C and ISO 9899:1990 say the type long long doesn't exist in strictly
  768. // conforming environments. ISO 9899:1999 says it does.
  769. //
  770. // The presence of _LONGLONG_TYPE says "long long exists" which is therefore
  771. // defined in all but strictly conforming environments that disallow it.
  772. // The following macro defines a value for the ISO C99 restrict
  773. // keyword so that _RESTRICT_KYWD resolves to "restrict" if
  774. // an ISO C99 compiler is used, "__restrict" for c++ and "" (null string)
  775. // if any other compiler is used. This allows for the use of single
  776. // prototype declarations regardless of compiler version.
  777. // The following macro defines a value for the ISO C11 _Noreturn
  778. // keyword so that _NORETURN_KYWD resolves to "_Noreturn" if
  779. // an ISO C11 compiler is used and "" (null string) if any other
  780. // compiler is used. This allows for the use of single prototype
  781. // declarations regardless of compiler version.
  782. // ISO/IEC 9899:2011 Annex K
  783. // The following macro indicates header support for the ANSI C++
  784. // standard. The ISO/IEC designation for this is ISO/IEC FDIS 14882.
  785. // The following macro indicates header support for the C99 standard,
  786. // ISO/IEC 9899:1999, Programming Languages - C.
  787. // The following macro indicates header support for the C11 standard,
  788. // ISO/IEC 9899:2011, Programming Languages - C.
  789. // The following macro indicates header support for the C11 standard,
  790. // ISO/IEC 9899:2011 Annex K, Programming Languages - C.
  791. // The following macro indicates header support for DTrace. The value is an
  792. // integer that corresponds to the major version number for DTrace.
  793. // CDDL HEADER START
  794. //
  795. // The contents of this file are subject to the terms of the
  796. // Common Development and Distribution License (the "License").
  797. // You may not use this file except in compliance with the License.
  798. //
  799. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  800. // or http://www.opensolaris.org/os/licensing.
  801. // See the License for the specific language governing permissions
  802. // and limitations under the License.
  803. //
  804. //
  805. // When distributing Covered Code, include this CDDL HEADER in each
  806. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  807. // If applicable, add the following below this CDDL HEADER, with the
  808. // fields enclosed by brackets "[]" replaced with your own identifying
  809. // information: Portions Copyright [yyyy] [name of copyright owner]
  810. //
  811. // CDDL HEADER END
  812. // Copyright 2008 Sun Microsystems, Inc. All rights reserved.
  813. // Use is subject to license terms.
  814. // Copyright 2016 Joyent, Inc.
  815. // Machine dependent definitions moved to <sys/machtypes.h>.
  816. // CDDL HEADER START
  817. //
  818. // The contents of this file are subject to the terms of the
  819. // Common Development and Distribution License (the "License").
  820. // You may not use this file except in compliance with the License.
  821. //
  822. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  823. // or http://www.opensolaris.org/os/licensing.
  824. // See the License for the specific language governing permissions
  825. // and limitations under the License.
  826. //
  827. // When distributing Covered Code, include this CDDL HEADER in each
  828. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  829. // If applicable, add the following below this CDDL HEADER, with the
  830. // fields enclosed by brackets "[]" replaced with your own identifying
  831. // information: Portions Copyright [yyyy] [name of copyright owner]
  832. //
  833. // CDDL HEADER END
  834. // Copyright 2007 Sun Microsystems, Inc. All rights reserved.
  835. // Use is subject to license terms.
  836. // Machine dependent types:
  837. //
  838. // intel ia32 Version
  839. type X_label_t = struct{ Fval [8]int64 } /* machtypes.h:59:9 */
  840. // CDDL HEADER START
  841. //
  842. // The contents of this file are subject to the terms of the
  843. // Common Development and Distribution License (the "License").
  844. // You may not use this file except in compliance with the License.
  845. //
  846. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  847. // or http://www.opensolaris.org/os/licensing.
  848. // See the License for the specific language governing permissions
  849. // and limitations under the License.
  850. //
  851. // When distributing Covered Code, include this CDDL HEADER in each
  852. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  853. // If applicable, add the following below this CDDL HEADER, with the
  854. // fields enclosed by brackets "[]" replaced with your own identifying
  855. // information: Portions Copyright [yyyy] [name of copyright owner]
  856. //
  857. // CDDL HEADER END
  858. // Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T
  859. // All Rights Reserved
  860. // Copyright 2009 Sun Microsystems, Inc. All rights reserved.
  861. // Use is subject to license terms.
  862. //
  863. // Copyright 2013 Nexenta Systems, Inc. All rights reserved.
  864. // Copyright 2016 Joyent, Inc.
  865. // Copyright 2021 Oxide Computer Company
  866. // DO NOT EDIT THIS FILE.
  867. //
  868. // It has been auto-edited by fixincludes from:
  869. //
  870. // "/usr/include/sys/feature_tests.h"
  871. //
  872. // This had to be done to correct non-standard usages in the
  873. // original, manufacturer supplied header file.
  874. // CDDL HEADER START
  875. //
  876. // The contents of this file are subject to the terms of the
  877. // Common Development and Distribution License (the "License").
  878. // You may not use this file except in compliance with the License.
  879. //
  880. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  881. // or http://www.opensolaris.org/os/licensing.
  882. // See the License for the specific language governing permissions
  883. // and limitations under the License.
  884. //
  885. // When distributing Covered Code, include this CDDL HEADER in each
  886. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  887. // If applicable, add the following below this CDDL HEADER, with the
  888. // fields enclosed by brackets "[]" replaced with your own identifying
  889. // information: Portions Copyright [yyyy] [name of copyright owner]
  890. //
  891. // CDDL HEADER END
  892. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  893. // Copyright 2016 Joyent, Inc.
  894. // Copyright 2022 Oxide Computer Company
  895. //
  896. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  897. // Use is subject to license terms.
  898. // CDDL HEADER START
  899. //
  900. // The contents of this file are subject to the terms of the
  901. // Common Development and Distribution License, Version 1.0 only
  902. // (the "License"). You may not use this file except in compliance
  903. // with the License.
  904. //
  905. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  906. // or http://www.opensolaris.org/os/licensing.
  907. // See the License for the specific language governing permissions
  908. // and limitations under the License.
  909. //
  910. // When distributing Covered Code, include this CDDL HEADER in each
  911. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  912. // If applicable, add the following below this CDDL HEADER, with the
  913. // fields enclosed by brackets "[]" replaced with your own identifying
  914. // information: Portions Copyright [yyyy] [name of copyright owner]
  915. //
  916. // CDDL HEADER END
  917. // Copyright 2004 Sun Microsystems, Inc. All rights reserved.
  918. // Use is subject to license terms.
  919. // Copyright 2015 EveryCity Ltd. All rights reserved.
  920. // Copyright 2019 Joyent, Inc.
  921. // This file contains definitions designed to enable different compilers
  922. // to be used harmoniously on Solaris systems.
  923. // Allow for version tests for compiler bugs and features.
  924. // analogous to lint's PRINTFLIKEn
  925. // Handle the kernel printf routines that can take '%b' too
  926. // This one's pretty obvious -- the function never returns
  927. // The function is 'extern inline' and expects GNU C89 behaviour, not C99
  928. // behaviour.
  929. //
  930. // Should only be used on 'extern inline' definitions for GCC.
  931. // The function has control flow such that it may return multiple times (in
  932. // the manner of setjmp or vfork)
  933. // This is an appropriate label for functions that do not
  934. // modify their arguments, e.g. strlen()
  935. // This is a stronger form of __pure__. Can be used for functions
  936. // that do not modify their arguments and don't depend on global
  937. // memory.
  938. // This attribute, attached to a variable, means that the variable is meant to
  939. // be possibly unused. GCC will not produce a warning for this variable.
  940. // Shorthand versions for readability
  941. // In release build, disable warnings about variables
  942. // which are used only for debugging.
  943. // CDDL HEADER START
  944. //
  945. // The contents of this file are subject to the terms of the
  946. // Common Development and Distribution License (the "License").
  947. // You may not use this file except in compliance with the License.
  948. //
  949. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  950. // or http://www.opensolaris.org/os/licensing.
  951. // See the License for the specific language governing permissions
  952. // and limitations under the License.
  953. //
  954. //
  955. // When distributing Covered Code, include this CDDL HEADER in each
  956. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  957. // If applicable, add the following below this CDDL HEADER, with the
  958. // fields enclosed by brackets "[]" replaced with your own identifying
  959. // information: Portions Copyright [yyyy] [name of copyright owner]
  960. //
  961. // CDDL HEADER END
  962. // Copyright 2008 Sun Microsystems, Inc. All rights reserved.
  963. // Use is subject to license terms.
  964. // Copyright 2016 Joyent, Inc.
  965. // This header file serves to group a set of well known defines and to
  966. // set these for each instruction set architecture. These defines may
  967. // be divided into two groups; characteristics of the processor and
  968. // implementation choices for Solaris on a processor.
  969. //
  970. // Processor Characteristics:
  971. //
  972. // _LITTLE_ENDIAN / _BIG_ENDIAN:
  973. // The natural byte order of the processor. A pointer to an int points
  974. // to the least/most significant byte of that int.
  975. //
  976. // _STACK_GROWS_UPWARD / _STACK_GROWS_DOWNWARD:
  977. // The processor specific direction of stack growth. A push onto the
  978. // stack increases/decreases the stack pointer, so it stores data at
  979. // successively higher/lower addresses. (Stackless machines ignored
  980. // without regrets).
  981. //
  982. // _LONG_LONG_HTOL / _LONG_LONG_LTOH:
  983. // A pointer to a long long points to the most/least significant long
  984. // within that long long.
  985. //
  986. // _BIT_FIELDS_HTOL / _BIT_FIELDS_LTOH:
  987. // The C compiler assigns bit fields from the high/low to the low/high end
  988. // of an int (most to least significant vs. least to most significant).
  989. //
  990. // _IEEE_754:
  991. // The processor (or supported implementations of the processor)
  992. // supports the ieee-754 floating point standard. No other floating
  993. // point standards are supported (or significant). Any other supported
  994. // floating point formats are expected to be cased on the ISA processor
  995. // symbol.
  996. //
  997. // _CHAR_IS_UNSIGNED / _CHAR_IS_SIGNED:
  998. // The C Compiler implements objects of type `char' as `unsigned' or
  999. // `signed' respectively. This is really an implementation choice of
  1000. // the compiler writer, but it is specified in the ABI and tends to
  1001. // be uniform across compilers for an instruction set architecture.
  1002. // Hence, it has the properties of a processor characteristic.
  1003. //
  1004. // _CHAR_ALIGNMENT / _SHORT_ALIGNMENT / _INT_ALIGNMENT / _LONG_ALIGNMENT /
  1005. // _LONG_LONG_ALIGNMENT / _DOUBLE_ALIGNMENT / _LONG_DOUBLE_ALIGNMENT /
  1006. // _POINTER_ALIGNMENT / _FLOAT_ALIGNMENT:
  1007. // The ABI defines alignment requirements of each of the primitive
  1008. // object types. Some, if not all, may be hardware requirements as
  1009. // well. The values are expressed in "byte-alignment" units.
  1010. //
  1011. // _MAX_ALIGNMENT:
  1012. // The most stringent alignment requirement as specified by the ABI.
  1013. // Equal to the maximum of all the above _XXX_ALIGNMENT values.
  1014. //
  1015. // _MAX_ALIGNMENT_TYPE:
  1016. // The name of the C type that has the value descried in _MAX_ALIGNMENT.
  1017. //
  1018. // _ALIGNMENT_REQUIRED:
  1019. // True or false (1 or 0) whether or not the hardware requires the ABI
  1020. // alignment.
  1021. //
  1022. // _LONG_LONG_ALIGNMENT_32
  1023. // The 32-bit ABI supported by a 64-bit kernel may have different
  1024. // alignment requirements for primitive object types. The value of this
  1025. // identifier is expressed in "byte-alignment" units.
  1026. //
  1027. // _HAVE_CPUID_INSN
  1028. // This indicates that the architecture supports the 'cpuid'
  1029. // instruction as defined by Intel. (Intel allows other vendors
  1030. // to extend the instruction for their own purposes.)
  1031. //
  1032. //
  1033. // Implementation Choices:
  1034. //
  1035. // _ILP32 / _LP64:
  1036. // This specifies the compiler data type implementation as specified in
  1037. // the relevant ABI. The choice between these is strongly influenced
  1038. // by the underlying hardware, but is not absolutely tied to it.
  1039. // Currently only two data type models are supported:
  1040. //
  1041. // _ILP32:
  1042. // Int/Long/Pointer are 32 bits. This is the historical UNIX
  1043. // and Solaris implementation. Due to its historical standing,
  1044. // this is the default case.
  1045. //
  1046. // _LP64:
  1047. // Long/Pointer are 64 bits, Int is 32 bits. This is the chosen
  1048. // implementation for 64-bit ABIs such as SPARC V9.
  1049. //
  1050. // _I32LPx:
  1051. // A compilation environment where 'int' is 32-bit, and
  1052. // longs and pointers are simply the same size.
  1053. //
  1054. // In all cases, Char is 8 bits and Short is 16 bits.
  1055. //
  1056. // _SUNOS_VTOC_8 / _SUNOS_VTOC_16 / _SVR4_VTOC_16:
  1057. // This specifies the form of the disk VTOC (or label):
  1058. //
  1059. // _SUNOS_VTOC_8:
  1060. // This is a VTOC form which is upwardly compatible with the
  1061. // SunOS 4.x disk label and allows 8 partitions per disk.
  1062. //
  1063. // _SUNOS_VTOC_16:
  1064. // In this format the incore vtoc image matches the ondisk
  1065. // version. It allows 16 slices per disk, and is not
  1066. // compatible with the SunOS 4.x disk label.
  1067. //
  1068. // Note that these are not the only two VTOC forms possible and
  1069. // additional forms may be added. One possible form would be the
  1070. // SVr4 VTOC form. The symbol for that is reserved now, although
  1071. // it is not implemented.
  1072. //
  1073. // _SVR4_VTOC_16:
  1074. // This VTOC form is compatible with the System V Release 4
  1075. // VTOC (as implemented on the SVr4 Intel and 3b ports) with
  1076. // 16 partitions per disk.
  1077. //
  1078. //
  1079. // _DMA_USES_PHYSADDR / _DMA_USES_VIRTADDR
  1080. // This describes the type of addresses used by system DMA:
  1081. //
  1082. // _DMA_USES_PHYSADDR:
  1083. // This type of DMA, used in the x86 implementation,
  1084. // requires physical addresses for DMA buffers. The 24-bit
  1085. // addresses used by some legacy boards is the source of the
  1086. // "low-memory" (<16MB) requirement for some devices using DMA.
  1087. //
  1088. // _DMA_USES_VIRTADDR:
  1089. // This method of DMA allows the use of virtual addresses for
  1090. // DMA transfers.
  1091. //
  1092. // _FIRMWARE_NEEDS_FDISK / _NO_FDISK_PRESENT
  1093. // This indicates the presence/absence of an fdisk table.
  1094. //
  1095. // _FIRMWARE_NEEDS_FDISK
  1096. // The fdisk table is required by system firmware. If present,
  1097. // it allows a disk to be subdivided into multiple fdisk
  1098. // partitions, each of which is equivalent to a separate,
  1099. // virtual disk. This enables the co-existence of multiple
  1100. // operating systems on a shared hard disk.
  1101. //
  1102. // _NO_FDISK_PRESENT
  1103. // If the fdisk table is absent, it is assumed that the entire
  1104. // media is allocated for a single operating system.
  1105. //
  1106. // _HAVE_TEM_FIRMWARE
  1107. // Defined if this architecture has the (fallback) option of
  1108. // using prom_* calls for doing I/O if a suitable kernel driver
  1109. // is not available to do it.
  1110. //
  1111. // _DONT_USE_1275_GENERIC_NAMES
  1112. // Controls whether or not device tree node names should
  1113. // comply with the IEEE 1275 "Generic Names" Recommended
  1114. // Practice. With _DONT_USE_GENERIC_NAMES, device-specific
  1115. // names identifying the particular device will be used.
  1116. //
  1117. // __i386_COMPAT
  1118. // This indicates whether the i386 ABI is supported as a *non-native*
  1119. // mode for the platform. When this symbol is defined:
  1120. // - 32-bit xstat-style system calls are enabled
  1121. // - 32-bit xmknod-style system calls are enabled
  1122. // - 32-bit system calls use i386 sizes -and- alignments
  1123. //
  1124. // Note that this is NOT defined for the i386 native environment!
  1125. //
  1126. // __x86
  1127. // This is ONLY a synonym for defined(__i386) || defined(__amd64)
  1128. // which is useful only insofar as these two architectures share
  1129. // common attributes. Analogous to __sparc.
  1130. //
  1131. // _PSM_MODULES
  1132. // This indicates whether or not the implementation uses PSM
  1133. // modules for processor support, reading /etc/mach from inside
  1134. // the kernel to extract a list.
  1135. //
  1136. // _RTC_CONFIG
  1137. // This indicates whether or not the implementation uses /etc/rtc_config
  1138. // to configure the real-time clock in the kernel.
  1139. //
  1140. // _UNIX_KRTLD
  1141. // This indicates that the implementation uses a dynamically
  1142. // linked unix + krtld to form the core kernel image at boot
  1143. // time, or (in the absence of this symbol) a prelinked kernel image.
  1144. //
  1145. // _OBP
  1146. // This indicates the firmware interface is OBP.
  1147. //
  1148. // _SOFT_HOSTID
  1149. // This indicates that the implementation obtains the hostid
  1150. // from the file /etc/hostid, rather than from hardware.
  1151. // The following set of definitions characterize Solaris on AMD's
  1152. // 64-bit systems.
  1153. // Define the appropriate "processor characteristics"
  1154. // Different alignment constraints for the i386 ABI in compatibility mode
  1155. // Define the appropriate "implementation choices".
  1156. // The feature test macro __i386 is generic for all processors implementing
  1157. // the Intel 386 instruction set or a superset of it. Specifically, this
  1158. // includes all members of the 386, 486, and Pentium family of processors.
  1159. // Values of _POSIX_C_SOURCE
  1160. //
  1161. // undefined not a POSIX compilation
  1162. // 1 POSIX.1-1990 compilation
  1163. // 2 POSIX.2-1992 compilation
  1164. // 199309L POSIX.1b-1993 compilation (Real Time)
  1165. // 199506L POSIX.1c-1995 compilation (POSIX Threads)
  1166. // 200112L POSIX.1-2001 compilation (Austin Group Revision)
  1167. // 200809L POSIX.1-2008 compilation
  1168. // The feature test macros __XOPEN_OR_POSIX, _STRICT_STDC, _STRICT_SYMBOLS,
  1169. // and _STDC_C99 are Sun implementation specific macros created in order to
  1170. // compress common standards specified feature test macros for easier reading.
  1171. // These macros should not be used by the application developer as
  1172. // unexpected results may occur. Instead, the user should reference
  1173. // standards(7) for correct usage of the standards feature test macros.
  1174. //
  1175. // __XOPEN_OR_POSIX Used in cases where a symbol is defined by both
  1176. // X/Open or POSIX or in the negative, when neither
  1177. // X/Open or POSIX defines a symbol.
  1178. //
  1179. // _STRICT_STDC __STDC__ is specified by the C Standards and defined
  1180. // by the compiler. For Sun compilers the value of
  1181. // __STDC__ is either 1, 0, or not defined based on the
  1182. // compilation mode (see cc(1)). When the value of
  1183. // __STDC__ is 1 and in the absence of any other feature
  1184. // test macros, the namespace available to the application
  1185. // is limited to only those symbols defined by the C
  1186. // Standard. _STRICT_STDC provides a more readable means
  1187. // of identifying symbols defined by the standard, or in
  1188. // the negative, symbols that are extensions to the C
  1189. // Standard. See additional comments for GNU C differences.
  1190. //
  1191. // _STDC_C99 __STDC_VERSION__ is specified by the C standards and
  1192. // defined by the compiler and indicates the version of
  1193. // the C standard. A value of 199901L indicates a
  1194. // compiler that complies with ISO/IEC 9899:1999, other-
  1195. // wise known as the C99 standard.
  1196. //
  1197. // _STDC_C11 Like _STDC_C99 except that the value of __STDC_VERSION__
  1198. // is 201112L indicating a compiler that compiles with
  1199. // ISO/IEC 9899:2011, otherwise known as the C11 standard.
  1200. //
  1201. // _STRICT_SYMBOLS Used in cases where symbol visibility is restricted
  1202. // by the standards, and the user has not explicitly
  1203. // relaxed the strictness via __EXTENSIONS__.
  1204. // ISO/IEC 9899:1990 and it's revisions, ISO/IEC 9899:1999 and ISO/IEC
  1205. // 99899:2011 specify the following predefined macro name:
  1206. //
  1207. // __STDC__ The integer constant 1, intended to indicate a conforming
  1208. // implementation.
  1209. //
  1210. // Furthermore, a strictly conforming program shall use only those features
  1211. // of the language and library specified in these standards. A conforming
  1212. // implementation shall accept any strictly conforming program.
  1213. //
  1214. // Based on these requirements, Sun's C compiler defines __STDC__ to 1 for
  1215. // strictly conforming environments and __STDC__ to 0 for environments that
  1216. // use ANSI C semantics but allow extensions to the C standard. For non-ANSI
  1217. // C semantics, Sun's C compiler does not define __STDC__.
  1218. //
  1219. // The GNU C project interpretation is that __STDC__ should always be defined
  1220. // to 1 for compilation modes that accept ANSI C syntax regardless of whether
  1221. // or not extensions to the C standard are used. Violations of conforming
  1222. // behavior are conditionally flagged as warnings via the use of the
  1223. // -pedantic option. In addition to defining __STDC__ to 1, the GNU C
  1224. // compiler also defines __STRICT_ANSI__ as a means of specifying strictly
  1225. // conforming environments using the -ansi or -std=<standard> options.
  1226. //
  1227. // In the absence of any other compiler options, Sun and GNU set the value
  1228. // of __STDC__ as follows when using the following options:
  1229. //
  1230. // Value of __STDC__ __STRICT_ANSI__
  1231. //
  1232. // cc -Xa (default) 0 undefined
  1233. // cc -Xt (transitional) 0 undefined
  1234. // cc -Xc (strictly conforming) 1 undefined
  1235. // cc -Xs (K&R C) undefined undefined
  1236. //
  1237. // gcc (default) 1 undefined
  1238. // gcc -ansi, -std={c89, c99,...) 1 defined
  1239. // gcc -traditional (K&R) undefined undefined
  1240. //
  1241. // The default compilation modes for Sun C compilers versus GNU C compilers
  1242. // results in a differing value for __STDC__ which results in a more
  1243. // restricted namespace when using Sun compilers. To allow both GNU and Sun
  1244. // interpretations to peacefully co-exist, we use the following Sun
  1245. // implementation _STRICT_STDC_ macro:
  1246. // Compiler complies with ISO/IEC 9899:1999 or ISO/IEC 9989:2011
  1247. // Use strict symbol visibility.
  1248. // This is a variant of _STRICT_SYMBOLS that is meant to cover headers that are
  1249. // governed by POSIX, but have not been governed by ISO C. One can go two ways
  1250. // on what should happen if an application actively includes (not transitively)
  1251. // a header that isn't part of the ISO C spec, we opt to say that if someone has
  1252. // gone out of there way then they're doing it for a reason and that is an act
  1253. // of non-compliance and therefore it's not up to us to hide away every symbol.
  1254. //
  1255. // In general, prefer using _STRICT_SYMBOLS, but this is here in particular for
  1256. // cases where in the past we have only used a POSIX related check and we don't
  1257. // wish to make something stricter. Often applications are relying on the
  1258. // ability to, or more realistically unwittingly, have _STRICT_STDC declared and
  1259. // still use these interfaces.
  1260. // Large file interfaces:
  1261. //
  1262. // _LARGEFILE_SOURCE
  1263. // 1 large file-related additions to POSIX
  1264. // interfaces requested (fseeko, etc.)
  1265. // _LARGEFILE64_SOURCE
  1266. // 1 transitional large-file-related interfaces
  1267. // requested (seek64, stat64, etc.)
  1268. //
  1269. // The corresponding announcement macros are respectively:
  1270. // _LFS_LARGEFILE
  1271. // _LFS64_LARGEFILE
  1272. // (These are set in <unistd.h>.)
  1273. //
  1274. // Requesting _LARGEFILE64_SOURCE implies requesting _LARGEFILE_SOURCE as
  1275. // well.
  1276. //
  1277. // The large file interfaces are made visible regardless of the initial values
  1278. // of the feature test macros under certain circumstances:
  1279. // - If no explicit standards-conforming environment is requested (neither
  1280. // of _POSIX_SOURCE nor _XOPEN_SOURCE is defined and the value of
  1281. // __STDC__ does not imply standards conformance).
  1282. // - Extended system interfaces are explicitly requested (__EXTENSIONS__
  1283. // is defined).
  1284. // - Access to in-kernel interfaces is requested (_KERNEL or _KMEMUSER is
  1285. // defined). (Note that this dependency is an artifact of the current
  1286. // kernel implementation and may change in future releases.)
  1287. // Large file compilation environment control:
  1288. //
  1289. // The setting of _FILE_OFFSET_BITS controls the size of various file-related
  1290. // types and governs the mapping between file-related source function symbol
  1291. // names and the corresponding binary entry points.
  1292. //
  1293. // In the 32-bit environment, the default value is 32; if not set, set it to
  1294. // the default here, to simplify tests in other headers.
  1295. //
  1296. // In the 64-bit compilation environment, the only value allowed is 64.
  1297. // Use of _XOPEN_SOURCE
  1298. //
  1299. // The following X/Open specifications are supported:
  1300. //
  1301. // X/Open Portability Guide, Issue 3 (XPG3)
  1302. // X/Open CAE Specification, Issue 4 (XPG4)
  1303. // X/Open CAE Specification, Issue 4, Version 2 (XPG4v2)
  1304. // X/Open CAE Specification, Issue 5 (XPG5)
  1305. // Open Group Technical Standard, Issue 6 (XPG6), also referred to as
  1306. // IEEE Std. 1003.1-2001 and ISO/IEC 9945:2002.
  1307. // Open Group Technical Standard, Issue 7 (XPG7), also referred to as
  1308. // IEEE Std. 1003.1-2008 and ISO/IEC 9945:2009.
  1309. //
  1310. // XPG4v2 is also referred to as UNIX 95 (SUS or SUSv1).
  1311. // XPG5 is also referred to as UNIX 98 or the Single Unix Specification,
  1312. // Version 2 (SUSv2)
  1313. // XPG6 is the result of a merge of the X/Open and POSIX specifications
  1314. // and as such is also referred to as IEEE Std. 1003.1-2001 in
  1315. // addition to UNIX 03 and SUSv3.
  1316. // XPG7 is also referred to as UNIX 08 and SUSv4.
  1317. //
  1318. // When writing a conforming X/Open application, as per the specification
  1319. // requirements, the appropriate feature test macros must be defined at
  1320. // compile time. These are as follows. For more info, see standards(7).
  1321. //
  1322. // Feature Test Macro Specification
  1323. // ------------------------------------------------ -------------
  1324. // _XOPEN_SOURCE XPG3
  1325. // _XOPEN_SOURCE && _XOPEN_VERSION = 4 XPG4
  1326. // _XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED = 1 XPG4v2
  1327. // _XOPEN_SOURCE = 500 XPG5
  1328. // _XOPEN_SOURCE = 600 (or POSIX_C_SOURCE=200112L) XPG6
  1329. // _XOPEN_SOURCE = 700 (or POSIX_C_SOURCE=200809L) XPG7
  1330. //
  1331. // In order to simplify the guards within the headers, the following
  1332. // implementation private test macros have been created. Applications
  1333. // must NOT use these private test macros as unexpected results will
  1334. // occur.
  1335. //
  1336. // Note that in general, the use of these private macros is cumulative.
  1337. // For example, the use of _XPG3 with no other restrictions on the X/Open
  1338. // namespace will make the symbols visible for XPG3 through XPG6
  1339. // compilation environments. The use of _XPG4_2 with no other X/Open
  1340. // namespace restrictions indicates that the symbols were introduced in
  1341. // XPG4v2 and are therefore visible for XPG4v2 through XPG6 compilation
  1342. // environments, but not for XPG3 or XPG4 compilation environments.
  1343. //
  1344. // _XPG3 X/Open Portability Guide, Issue 3 (XPG3)
  1345. // _XPG4 X/Open CAE Specification, Issue 4 (XPG4)
  1346. // _XPG4_2 X/Open CAE Specification, Issue 4, Version 2 (XPG4v2/UNIX 95/SUS)
  1347. // _XPG5 X/Open CAE Specification, Issue 5 (XPG5/UNIX 98/SUSv2)
  1348. // _XPG6 Open Group Technical Standard, Issue 6 (XPG6/UNIX 03/SUSv3)
  1349. // _XPG7 Open Group Technical Standard, Issue 7 (XPG7/UNIX 08/SUSv4)
  1350. // X/Open Portability Guide, Issue 3
  1351. // _XOPEN_VERSION is defined by the X/Open specifications and is not
  1352. // normally defined by the application, except in the case of an XPG4
  1353. // application. On the implementation side, _XOPEN_VERSION defined with
  1354. // the value of 3 indicates an XPG3 application. _XOPEN_VERSION defined
  1355. // with the value of 4 indicates an XPG4 or XPG4v2 (UNIX 95) application.
  1356. // _XOPEN_VERSION defined with a value of 500 indicates an XPG5 (UNIX 98)
  1357. // application and with a value of 600 indicates an XPG6 (UNIX 03)
  1358. // application and with a value of 700 indicates an XPG7 (UNIX 08).
  1359. // The appropriate version is determined by the use of the
  1360. // feature test macros described earlier. The value of _XOPEN_VERSION
  1361. // defaults to 3 otherwise indicating support for XPG3 applications.
  1362. // ANSI C and ISO 9899:1990 say the type long long doesn't exist in strictly
  1363. // conforming environments. ISO 9899:1999 says it does.
  1364. //
  1365. // The presence of _LONGLONG_TYPE says "long long exists" which is therefore
  1366. // defined in all but strictly conforming environments that disallow it.
  1367. // The following macro defines a value for the ISO C99 restrict
  1368. // keyword so that _RESTRICT_KYWD resolves to "restrict" if
  1369. // an ISO C99 compiler is used, "__restrict" for c++ and "" (null string)
  1370. // if any other compiler is used. This allows for the use of single
  1371. // prototype declarations regardless of compiler version.
  1372. // The following macro defines a value for the ISO C11 _Noreturn
  1373. // keyword so that _NORETURN_KYWD resolves to "_Noreturn" if
  1374. // an ISO C11 compiler is used and "" (null string) if any other
  1375. // compiler is used. This allows for the use of single prototype
  1376. // declarations regardless of compiler version.
  1377. // ISO/IEC 9899:2011 Annex K
  1378. // The following macro indicates header support for the ANSI C++
  1379. // standard. The ISO/IEC designation for this is ISO/IEC FDIS 14882.
  1380. // The following macro indicates header support for the C99 standard,
  1381. // ISO/IEC 9899:1999, Programming Languages - C.
  1382. // The following macro indicates header support for the C11 standard,
  1383. // ISO/IEC 9899:2011, Programming Languages - C.
  1384. // The following macro indicates header support for the C11 standard,
  1385. // ISO/IEC 9899:2011 Annex K, Programming Languages - C.
  1386. // The following macro indicates header support for DTrace. The value is an
  1387. // integer that corresponds to the major version number for DTrace.
  1388. // CDDL HEADER START
  1389. //
  1390. // The contents of this file are subject to the terms of the
  1391. // Common Development and Distribution License (the "License").
  1392. // You may not use this file except in compliance with the License.
  1393. //
  1394. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  1395. // or http://www.opensolaris.org/os/licensing.
  1396. // See the License for the specific language governing permissions
  1397. // and limitations under the License.
  1398. //
  1399. //
  1400. // When distributing Covered Code, include this CDDL HEADER in each
  1401. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  1402. // If applicable, add the following below this CDDL HEADER, with the
  1403. // fields enclosed by brackets "[]" replaced with your own identifying
  1404. // information: Portions Copyright [yyyy] [name of copyright owner]
  1405. //
  1406. // CDDL HEADER END
  1407. // Copyright 2008 Sun Microsystems, Inc. All rights reserved.
  1408. // Use is subject to license terms.
  1409. // Copyright 2016 Joyent, Inc.
  1410. // Machine dependent definitions moved to <sys/machtypes.h>.
  1411. // CDDL HEADER START
  1412. //
  1413. // The contents of this file are subject to the terms of the
  1414. // Common Development and Distribution License (the "License").
  1415. // You may not use this file except in compliance with the License.
  1416. //
  1417. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  1418. // or http://www.opensolaris.org/os/licensing.
  1419. // See the License for the specific language governing permissions
  1420. // and limitations under the License.
  1421. //
  1422. // When distributing Covered Code, include this CDDL HEADER in each
  1423. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  1424. // If applicable, add the following below this CDDL HEADER, with the
  1425. // fields enclosed by brackets "[]" replaced with your own identifying
  1426. // information: Portions Copyright [yyyy] [name of copyright owner]
  1427. //
  1428. // CDDL HEADER END
  1429. // Copyright 2007 Sun Microsystems, Inc. All rights reserved.
  1430. // Use is subject to license terms.
  1431. // Machine dependent types:
  1432. //
  1433. // intel ia32 Version
  1434. type Label_t = X_label_t /* machtypes.h:59:54 */
  1435. type Lock_t = uint8 /* machtypes.h:63:23 */ // lock work for busy wait
  1436. // Include fixed width type declarations proposed by the ISO/JTC1/SC22/WG14 C
  1437. // committee's working draft for the revision of the current ISO C standard,
  1438. // ISO/IEC 9899:1990 Programming language - C. These are not currently
  1439. // required by any standard but constitute a useful, general purpose set
  1440. // of type definitions which is namespace clean with respect to all standards.
  1441. // CDDL HEADER START
  1442. //
  1443. // The contents of this file are subject to the terms of the
  1444. // Common Development and Distribution License, Version 1.0 only
  1445. // (the "License"). You may not use this file except in compliance
  1446. // with the License.
  1447. //
  1448. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  1449. // or http://www.opensolaris.org/os/licensing.
  1450. // See the License for the specific language governing permissions
  1451. // and limitations under the License.
  1452. //
  1453. // When distributing Covered Code, include this CDDL HEADER in each
  1454. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  1455. // If applicable, add the following below this CDDL HEADER, with the
  1456. // fields enclosed by brackets "[]" replaced with your own identifying
  1457. // information: Portions Copyright [yyyy] [name of copyright owner]
  1458. //
  1459. // CDDL HEADER END
  1460. // Copyright 2014 Garrett D'Amore <garrett@damore.org>
  1461. //
  1462. // Copyright 2004 Sun Microsystems, Inc. All rights reserved.
  1463. // Use is subject to license terms.
  1464. // This file, <sys/int_types.h>, is part of the Sun Microsystems implementation
  1465. // of <inttypes.h> defined in the ISO C standard, ISO/IEC 9899:1999
  1466. // Programming language - C.
  1467. //
  1468. // Programs/Modules should not directly include this file. Access to the
  1469. // types defined in this file should be through the inclusion of one of the
  1470. // following files:
  1471. //
  1472. // <sys/types.h> Provides only the "_t" types defined in this
  1473. // file which is a subset of the contents of
  1474. // <inttypes.h>. (This can be appropriate for
  1475. // all programs/modules except those claiming
  1476. // ANSI-C conformance.)
  1477. //
  1478. // <sys/inttypes.h> Provides the Kernel and Driver appropriate
  1479. // components of <inttypes.h>.
  1480. //
  1481. // <inttypes.h> For use by applications.
  1482. //
  1483. // See these files for more details.
  1484. // DO NOT EDIT THIS FILE.
  1485. //
  1486. // It has been auto-edited by fixincludes from:
  1487. //
  1488. // "/usr/include/sys/feature_tests.h"
  1489. //
  1490. // This had to be done to correct non-standard usages in the
  1491. // original, manufacturer supplied header file.
  1492. // CDDL HEADER START
  1493. //
  1494. // The contents of this file are subject to the terms of the
  1495. // Common Development and Distribution License (the "License").
  1496. // You may not use this file except in compliance with the License.
  1497. //
  1498. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  1499. // or http://www.opensolaris.org/os/licensing.
  1500. // See the License for the specific language governing permissions
  1501. // and limitations under the License.
  1502. //
  1503. // When distributing Covered Code, include this CDDL HEADER in each
  1504. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  1505. // If applicable, add the following below this CDDL HEADER, with the
  1506. // fields enclosed by brackets "[]" replaced with your own identifying
  1507. // information: Portions Copyright [yyyy] [name of copyright owner]
  1508. //
  1509. // CDDL HEADER END
  1510. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  1511. // Copyright 2016 Joyent, Inc.
  1512. // Copyright 2022 Oxide Computer Company
  1513. //
  1514. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  1515. // Use is subject to license terms.
  1516. // Basic / Extended integer types
  1517. //
  1518. // The following defines the basic fixed-size integer types.
  1519. //
  1520. // Implementations are free to typedef them to Standard C integer types or
  1521. // extensions that they support. If an implementation does not support one
  1522. // of the particular integer data types below, then it should not define the
  1523. // typedefs and macros corresponding to that data type. Note that int8_t
  1524. // is not defined in -Xs mode on ISAs for which the ABI specifies "char"
  1525. // as an unsigned entity because there is no way to define an eight bit
  1526. // signed integral.
  1527. type Int8_t = int8 /* int_types.h:75:16 */
  1528. type Int16_t = int16 /* int_types.h:79:17 */
  1529. type Int32_t = int32 /* int_types.h:80:15 */
  1530. type Int64_t = int64 /* int_types.h:83:16 */
  1531. type Uint8_t = uint8 /* int_types.h:91:24 */
  1532. type Uint16_t = uint16 /* int_types.h:92:25 */
  1533. type Uint32_t = uint32 /* int_types.h:93:23 */
  1534. type Uint64_t = uint64 /* int_types.h:95:24 */
  1535. // intmax_t and uintmax_t are to be the longest (in number of bits) signed
  1536. // and unsigned integer types supported by the implementation.
  1537. type Intmax_t = int64 /* int_types.h:107:19 */
  1538. type Uintmax_t = uint64 /* int_types.h:108:19 */
  1539. // intptr_t and uintptr_t are signed and unsigned integer types large enough
  1540. // to hold any data pointer; that is, data pointers can be assigned into or
  1541. // from these integer types without losing precision.
  1542. type Intptr_t = int64 /* int_types.h:120:16 */
  1543. type Uintptr_t = uint64 /* int_types.h:121:24 */
  1544. // The following define the fastest integer types that can hold the
  1545. // specified number of bits.
  1546. type Int_fast8_t = int8 /* int_types.h:132:16 */
  1547. type Int_fast16_t = int32 /* int_types.h:136:15 */
  1548. type Int_fast32_t = int32 /* int_types.h:137:15 */
  1549. type Int_fast64_t = int64 /* int_types.h:139:16 */
  1550. type Uint_fast8_t = uint8 /* int_types.h:146:24 */
  1551. type Uint_fast16_t = uint32 /* int_types.h:147:23 */
  1552. type Uint_fast32_t = uint32 /* int_types.h:148:23 */
  1553. type Uint_fast64_t = uint64 /* int_types.h:150:24 */
  1554. // The following define the smallest integer types that can hold the
  1555. // specified number of bits.
  1556. type Int_least8_t = int8 /* int_types.h:162:16 */
  1557. type Int_least16_t = int16 /* int_types.h:166:17 */
  1558. type Int_least32_t = int32 /* int_types.h:167:15 */
  1559. type Int_least64_t = int64 /* int_types.h:169:16 */
  1560. // If these are changed, please update char16_t and char32_t in head/uchar.h.
  1561. type Uint_least8_t = uint8 /* int_types.h:179:24 */
  1562. type Uint_least16_t = uint16 /* int_types.h:180:25 */
  1563. type Uint_least32_t = uint32 /* int_types.h:181:23 */
  1564. type Uint_least64_t = uint64 /* int_types.h:183:24 */
  1565. // Strictly conforming ANSI C environments prior to the 1999
  1566. // revision of the C Standard (ISO/IEC 9899:1999) do not have
  1567. // the long long data type.
  1568. type Longlong_t = int64 /* types.h:72:20 */
  1569. type U_longlong_t = uint64 /* types.h:73:28 */
  1570. // These types (t_{u}scalar_t) exist because the XTI/TPI/DLPI standards had
  1571. // to use them instead of int32_t and uint32_t because DEC had
  1572. // shipped 64-bit wide.
  1573. type T_scalar_t = int32 /* types.h:92:18 */
  1574. type T_uscalar_t = uint32 /* types.h:93:18 */
  1575. // POSIX Extensions
  1576. type Uchar_t = uint8 /* types.h:102:23 */
  1577. type Ushort_t = uint16 /* types.h:103:24 */
  1578. type Uint_t = uint32 /* types.h:104:22 */
  1579. type Ulong_t = uint64 /* types.h:105:23 */
  1580. type Caddr_t = uintptr /* types.h:107:15 */ // ?<core address> type
  1581. type Daddr_t = int64 /* types.h:108:15 */ // <disk address> type
  1582. type Cnt_t = int16 /* types.h:109:16 */ // pointer difference
  1583. // VM-related types
  1584. type Pfn_t = uint64 /* types.h:123:18 */ // page frame number
  1585. type Pgcnt_t = uint64 /* types.h:124:18 */ // number of pages
  1586. type Spgcnt_t = int64 /* types.h:125:15 */ // signed number of pages
  1587. type Use_t = uint8 /* types.h:127:18 */ // use count for swap.
  1588. type Sysid_t = int16 /* types.h:128:16 */
  1589. type Index_t = int16 /* types.h:129:16 */
  1590. type Timeout_id_t = uintptr /* types.h:130:15 */ // opaque handle from timeout(9F)
  1591. type Bufcall_id_t = uintptr /* types.h:131:15 */ // opaque handle from bufcall(9F)
  1592. // The size of off_t and related types depends on the setting of
  1593. // _FILE_OFFSET_BITS. (Note that other system headers define other types
  1594. // related to those defined here.)
  1595. //
  1596. // If _LARGEFILE64_SOURCE is defined, variants of these types that are
  1597. // explicitly 64 bits wide become available.
  1598. type Off_t = int64 /* types.h:145:15 */ // offsets within files
  1599. type Off64_t = int64 /* types.h:152:16 */ // offsets within files
  1600. type Ino_t = uint64 /* types.h:161:18 */ // expanded inode type
  1601. type Blkcnt_t = int64 /* types.h:162:15 */ // count of file blocks
  1602. type Fsblkcnt_t = uint64 /* types.h:163:18 */ // count of file system blocks
  1603. type Fsfilcnt_t = uint64 /* types.h:164:18 */ // count of files
  1604. type Ino64_t = uint64 /* types.h:174:16 */ // expanded inode type
  1605. type Blkcnt64_t = int64 /* types.h:175:18 */ // count of file blocks
  1606. type Fsblkcnt64_t = uint64 /* types.h:176:20 */ // count of file system blocks
  1607. type Fsfilcnt64_t = uint64 /* types.h:177:20 */ // count of files
  1608. type Blksize_t = int32 /* types.h:187:14 */ // used for block sizes
  1609. // The boolean_t type has had a varied amount of exposure over the years in
  1610. // terms of how its enumeration constants have been exposed. In particular, it
  1611. // originally used the __XOPEN_OR_POSIX macro to determine whether to prefix the
  1612. // B_TRUE and B_FALSE with an underscore. This check never included the
  1613. // question of if we were in a strict ANSI C environment or whether extensions
  1614. // were defined.
  1615. //
  1616. // Compilers such as clang started defaulting to always including an
  1617. // XOPEN_SOURCE declaration on behalf of users, but also noted __EXTENSIONS__.
  1618. // This would lead most software that had used the non-underscore versions to
  1619. // need it. As such, we have adjusted the non-strict XOPEN environment to retain
  1620. // its old behavior so as to minimize namespace pollution; however, we instead
  1621. // include both variants of the definitions in the generally visible version
  1622. // allowing software written in either world to hopefully end up in a good
  1623. // place.
  1624. //
  1625. // This isn't perfect, but should hopefully minimize the pain for folks actually
  1626. // trying to build software.
  1627. type Boolean_t = uint32 /* types.h:215:69 */
  1628. // The {u,}pad64_t types can be used in structures such that those structures
  1629. // may be accessed by code produced by compilation environments which don't
  1630. // support a 64 bit integral datatype. The intention is not to allow
  1631. // use of these fields in such environments, but to maintain the alignment
  1632. // and offsets of the structure.
  1633. //
  1634. // Similar comments for {u,}pad128_t.
  1635. //
  1636. // Note that these types do NOT generate any stronger alignment constraints
  1637. // than those available in the underlying ABI. See <sys/isa_defs.h>
  1638. type Pad64_t = int64 /* types.h:240:18 */
  1639. type Upad64_t = uint64 /* types.h:241:18 */
  1640. type Pad128_t = struct {
  1641. F_q float64
  1642. F__ccgo_pad1 [8]byte
  1643. } /* types.h:257:3 */
  1644. type Upad128_t = struct {
  1645. F_q float64
  1646. F__ccgo_pad1 [8]byte
  1647. } /* types.h:262:3 */
  1648. type Offset_t = int64 /* types.h:264:20 */
  1649. type U_offset_t = uint64 /* types.h:265:22 */
  1650. type Len_t = uint64 /* types.h:266:22 */
  1651. type Diskaddr_t = uint64 /* types.h:267:22 */
  1652. // Definitions remaining from previous partial support for 64-bit file
  1653. // offsets. This partial support for devices greater than 2gb requires
  1654. // compiler support for long long.
  1655. type Lloff_t = struct{ F_f int64 } /* types.h:284:3 */
  1656. type Lldaddr_t = struct{ F_f int64 } /* types.h:304:3 */
  1657. type K_fltset_t = uint32 /* types.h:317:16 */ // kernel fault set type
  1658. // The following type is for various kinds of identifiers. The
  1659. // actual type must be the same for all since some system calls
  1660. // (such as sigsend) take arguments that may be any of these
  1661. // types. The enumeration type idtype_t defined in sys/procset.h
  1662. // is used to indicate what type of id is being specified --
  1663. // a process id, process group id, session id, scheduling class id,
  1664. // user id, group id, project id, task id or zone id.
  1665. type Id_t = int32 /* types.h:329:14 */
  1666. type Lgrp_id_t = int32 /* types.h:334:15 */ // lgroup ID
  1667. // Type useconds_t is an unsigned integral type capable of storing
  1668. // values at least in the range of zero to 1,000,000.
  1669. type Useconds_t = uint32 /* types.h:340:17 */ // Time, in microseconds
  1670. type Suseconds_t = int64 /* types.h:344:14 */ // signed # of microseconds
  1671. // Typedefs for dev_t components.
  1672. type Major_t = uint32 /* types.h:351:16 */ // major part of device number
  1673. type Minor_t = uint32 /* types.h:352:16 */ // minor part of device number
  1674. // The data type of a thread priority.
  1675. type Pri_t = int16 /* types.h:361:15 */
  1676. // The data type for a CPU flags field. (Can be extended to larger unsigned
  1677. // types, if needed, limited by ability to update atomically.)
  1678. type Cpu_flag_t = uint16 /* types.h:367:18 */
  1679. // For compatibility reasons the following typedefs (prefixed o_)
  1680. // can't grow regardless of the EFT definition. Although,
  1681. // applications should not explicitly use these typedefs
  1682. // they may be included via a system header definition.
  1683. // WARNING: These typedefs may be removed in a future
  1684. // release.
  1685. //
  1686. // ex. the definitions in s5inode.h (now obsoleted)
  1687. // remained small to preserve compatibility
  1688. // in the S5 file system type.
  1689. type O_mode_t = uint16 /* types.h:380:18 */ // old file attribute type
  1690. type O_dev_t = int16 /* types.h:381:15 */ // old device type
  1691. type O_uid_t = uint16 /* types.h:382:18 */ // old UID type
  1692. type O_gid_t = uint16 /* types.h:383:17 */ // old GID type
  1693. type O_nlink_t = int16 /* types.h:384:15 */ // old file link type
  1694. type O_pid_t = int16 /* types.h:385:15 */ // old process id type
  1695. type O_ino_t = uint16 /* types.h:386:18 */ // old inode type
  1696. // POSIX and XOPEN Declarations
  1697. type Key_t = int32 /* types.h:392:13 */ // IPC key type
  1698. type Mode_t = uint32 /* types.h:394:16 */ // file attribute type
  1699. type Uid_t = uint32 /* types.h:401:22 */ // UID type
  1700. type Gid_t = uint32 /* types.h:404:15 */ // GID type
  1701. type Datalink_id_t = uint32 /* types.h:406:18 */
  1702. type Vrid_t = uint32 /* types.h:407:18 */
  1703. type Taskid_t = int32 /* types.h:409:17 */
  1704. type Projid_t = int32 /* types.h:410:17 */
  1705. type Poolid_t = int32 /* types.h:411:14 */
  1706. type Zoneid_t = int32 /* types.h:412:14 */
  1707. type Ctid_t = int32 /* types.h:413:14 */
  1708. // POSIX definitions are same as defined in thread.h and synch.h.
  1709. // Any changes made to here should be reflected in corresponding
  1710. // files as described in comments.
  1711. type Pthread_t = uint32 /* types.h:420:16 */ // = thread_t in thread.h
  1712. type Pthread_key_t = uint32 /* types.h:421:16 */ // = thread_key_t in thread.h
  1713. // "Magic numbers" tagging synchronization object types
  1714. type X_pthread_mutex = struct {
  1715. F__pthread_mutex_flags struct {
  1716. F__pthread_mutex_flag1 uint16
  1717. F__pthread_mutex_flag2 uint8
  1718. F__pthread_mutex_ceiling uint8
  1719. F__pthread_mutex_type uint16
  1720. F__pthread_mutex_magic uint16
  1721. }
  1722. F__pthread_mutex_lock struct {
  1723. F__ccgo_pad1 [0]uint64
  1724. F__pthread_mutex_lock64 struct{ F__pthread_mutex_pad [8]uint8 }
  1725. }
  1726. F__pthread_mutex_data uint64
  1727. } /* types.h:429:9 */
  1728. // = thread_key_t in thread.h
  1729. // "Magic numbers" tagging synchronization object types
  1730. type Pthread_mutex_t = X_pthread_mutex /* types.h:448:3 */
  1731. type X_pthread_cond = struct {
  1732. F__pthread_cond_flags struct {
  1733. F__pthread_cond_flag [4]uint8
  1734. F__pthread_cond_type uint16
  1735. F__pthread_cond_magic uint16
  1736. }
  1737. F__pthread_cond_data uint64
  1738. } /* types.h:450:9 */
  1739. type Pthread_cond_t = X_pthread_cond /* types.h:457:3 */
  1740. // UNIX 98 Extension
  1741. type X_pthread_rwlock = struct {
  1742. F__pthread_rwlock_readers int32
  1743. F__pthread_rwlock_type uint16
  1744. F__pthread_rwlock_magic uint16
  1745. F__pthread_rwlock_mutex Pthread_mutex_t
  1746. F__pthread_rwlock_readercv Pthread_cond_t
  1747. F__pthread_rwlock_writercv Pthread_cond_t
  1748. } /* types.h:462:9 */
  1749. // UNIX 98 Extension
  1750. type Pthread_rwlock_t = X_pthread_rwlock /* types.h:469:3 */
  1751. // SUSV3
  1752. type Pthread_barrier_t = struct {
  1753. F__pthread_barrier_count uint32
  1754. F__pthread_barrier_current uint32
  1755. F__pthread_barrier_cycle uint64
  1756. F__pthread_barrier_reserved uint64
  1757. F__pthread_barrier_lock Pthread_mutex_t
  1758. F__pthread_barrier_cond Pthread_cond_t
  1759. } /* types.h:481:3 */
  1760. type Pthread_spinlock_t = Pthread_mutex_t /* types.h:483:25 */
  1761. // attributes for threads, dynamically allocated by library
  1762. type X_pthread_attr = struct{ F__pthread_attrp uintptr } /* types.h:488:9 */
  1763. // attributes for threads, dynamically allocated by library
  1764. type Pthread_attr_t = X_pthread_attr /* types.h:490:3 */
  1765. // attributes for mutex, dynamically allocated by library
  1766. type X_pthread_mutexattr = struct{ F__pthread_mutexattrp uintptr } /* types.h:495:9 */
  1767. // attributes for mutex, dynamically allocated by library
  1768. type Pthread_mutexattr_t = X_pthread_mutexattr /* types.h:497:3 */
  1769. // attributes for cond, dynamically allocated by library
  1770. type X_pthread_condattr = struct{ F__pthread_condattrp uintptr } /* types.h:502:9 */
  1771. // attributes for cond, dynamically allocated by library
  1772. type Pthread_condattr_t = X_pthread_condattr /* types.h:504:3 */
  1773. // pthread_once
  1774. type X_once = struct{ F__pthread_once_pad [4]uint64 } /* types.h:509:9 */
  1775. // pthread_once
  1776. type Pthread_once_t = X_once /* types.h:511:3 */
  1777. // UNIX 98 Extensions
  1778. // attributes for rwlock, dynamically allocated by library
  1779. type X_pthread_rwlockattr = struct{ F__pthread_rwlockattrp uintptr } /* types.h:517:9 */
  1780. // UNIX 98 Extensions
  1781. // attributes for rwlock, dynamically allocated by library
  1782. type Pthread_rwlockattr_t = X_pthread_rwlockattr /* types.h:519:3 */
  1783. // SUSV3
  1784. // attributes for pthread_barrier_t, dynamically allocated by library
  1785. type Pthread_barrierattr_t = struct{ F__pthread_barrierattrp uintptr } /* types.h:527:3 */
  1786. type Dev_t = uint64 /* types.h:529:17 */ // expanded device type
  1787. type Nlink_t = uint32 /* types.h:532:16 */ // file link type
  1788. type Pid_t = int32 /* types.h:533:13 */ // size of something in bytes
  1789. type Ssize_t = int64 /* types.h:551:14 */ // size of something in bytes or -1
  1790. type Time_t = int64 /* types.h:559:15 */ // time of day in seconds
  1791. type Clock_t = int64 /* types.h:564:15 */ // relative time in a specified resolution
  1792. type Clockid_t = int32 /* types.h:569:13 */ // clock identifier type
  1793. type Timer_t = int32 /* types.h:574:13 */ // timer identifier type
  1794. // BEGIN CSTYLED
  1795. type Unchar = uint8 /* types.h:580:23 */
  1796. type Ushort = uint16 /* types.h:581:24 */
  1797. type Uint = uint32 /* types.h:582:22 */
  1798. type Ulong = uint64 /* types.h:583:23 */
  1799. // END CSTYLED
  1800. // The following is the value of type id_t to use to indicate the
  1801. // caller's current id. See procset.h for the type idtype_t
  1802. // which defines which kind of id is being specified.
  1803. // The following value of type pfn_t is used to indicate
  1804. // invalid page frame number.
  1805. // BEGIN CSTYLED
  1806. type U_char = uint8 /* types.h:650:23 */
  1807. type U_short = uint16 /* types.h:651:24 */
  1808. type U_int = uint32 /* types.h:652:22 */
  1809. type U_long = uint64 /* types.h:653:23 */
  1810. type X_quad = struct{ Fval [2]int32 } /* types.h:654:9 */
  1811. type Quad_t = X_quad /* types.h:654:38 */ // used by UFS
  1812. type Quad = Quad_t /* types.h:655:17 */ // used by UFS
  1813. // END CSTYLED
  1814. // Nested include for BSD/sockets source compatibility.
  1815. // (The select macros used to be defined here).
  1816. // CDDL HEADER START
  1817. //
  1818. // The contents of this file are subject to the terms of the
  1819. // Common Development and Distribution License (the "License").
  1820. // You may not use this file except in compliance with the License.
  1821. //
  1822. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  1823. // or http://www.opensolaris.org/os/licensing.
  1824. // See the License for the specific language governing permissions
  1825. // and limitations under the License.
  1826. //
  1827. // When distributing Covered Code, include this CDDL HEADER in each
  1828. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  1829. // If applicable, add the following below this CDDL HEADER, with the
  1830. // fields enclosed by brackets "[]" replaced with your own identifying
  1831. // information: Portions Copyright [yyyy] [name of copyright owner]
  1832. //
  1833. // CDDL HEADER END
  1834. // Copyright 2014 Garrett D'Amore <garrett@damore.org>
  1835. //
  1836. // Copyright 2013 Nexenta Systems, Inc. All rights reserved.
  1837. //
  1838. // Copyright 2010 Sun Microsystems, Inc. All rights reserved.
  1839. // Use is subject to license terms.
  1840. // Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T
  1841. // All Rights Reserved
  1842. // University Copyright- Copyright (c) 1982, 1986, 1988
  1843. // The Regents of the University of California
  1844. // All Rights Reserved
  1845. //
  1846. // University Acknowledgment- Portions of this document are derived from
  1847. // software developed by the University of California, Berkeley, and its
  1848. // contributors.
  1849. // DO NOT EDIT THIS FILE.
  1850. //
  1851. // It has been auto-edited by fixincludes from:
  1852. //
  1853. // "/usr/include/sys/feature_tests.h"
  1854. //
  1855. // This had to be done to correct non-standard usages in the
  1856. // original, manufacturer supplied header file.
  1857. // CDDL HEADER START
  1858. //
  1859. // The contents of this file are subject to the terms of the
  1860. // Common Development and Distribution License (the "License").
  1861. // You may not use this file except in compliance with the License.
  1862. //
  1863. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  1864. // or http://www.opensolaris.org/os/licensing.
  1865. // See the License for the specific language governing permissions
  1866. // and limitations under the License.
  1867. //
  1868. // When distributing Covered Code, include this CDDL HEADER in each
  1869. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  1870. // If applicable, add the following below this CDDL HEADER, with the
  1871. // fields enclosed by brackets "[]" replaced with your own identifying
  1872. // information: Portions Copyright [yyyy] [name of copyright owner]
  1873. //
  1874. // CDDL HEADER END
  1875. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  1876. // Copyright 2016 Joyent, Inc.
  1877. // Copyright 2022 Oxide Computer Company
  1878. //
  1879. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  1880. // Use is subject to license terms.
  1881. // CDDL HEADER START
  1882. //
  1883. // The contents of this file are subject to the terms of the
  1884. // Common Development and Distribution License, Version 1.0 only
  1885. // (the "License"). You may not use this file except in compliance
  1886. // with the License.
  1887. //
  1888. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  1889. // or http://www.opensolaris.org/os/licensing.
  1890. // See the License for the specific language governing permissions
  1891. // and limitations under the License.
  1892. //
  1893. // When distributing Covered Code, include this CDDL HEADER in each
  1894. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  1895. // If applicable, add the following below this CDDL HEADER, with the
  1896. // fields enclosed by brackets "[]" replaced with your own identifying
  1897. // information: Portions Copyright [yyyy] [name of copyright owner]
  1898. //
  1899. // CDDL HEADER END
  1900. // Copyright 2005 Sun Microsystems, Inc. All rights reserved.
  1901. // Use is subject to license terms.
  1902. // Implementation-private. This header should not be included
  1903. // directly by an application. The application should instead
  1904. // include <time.h> which includes this header conditionally
  1905. // depending on which feature test macros are defined. By default,
  1906. // this header is included by <time.h>. X/Open and POSIX
  1907. // standards requirements result in this header being included
  1908. // by <time.h> only under a restricted set of conditions.
  1909. // DO NOT EDIT THIS FILE.
  1910. //
  1911. // It has been auto-edited by fixincludes from:
  1912. //
  1913. // "/usr/include/sys/feature_tests.h"
  1914. //
  1915. // This had to be done to correct non-standard usages in the
  1916. // original, manufacturer supplied header file.
  1917. // CDDL HEADER START
  1918. //
  1919. // The contents of this file are subject to the terms of the
  1920. // Common Development and Distribution License (the "License").
  1921. // You may not use this file except in compliance with the License.
  1922. //
  1923. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  1924. // or http://www.opensolaris.org/os/licensing.
  1925. // See the License for the specific language governing permissions
  1926. // and limitations under the License.
  1927. //
  1928. // When distributing Covered Code, include this CDDL HEADER in each
  1929. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  1930. // If applicable, add the following below this CDDL HEADER, with the
  1931. // fields enclosed by brackets "[]" replaced with your own identifying
  1932. // information: Portions Copyright [yyyy] [name of copyright owner]
  1933. //
  1934. // CDDL HEADER END
  1935. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  1936. // Copyright 2016 Joyent, Inc.
  1937. // Copyright 2022 Oxide Computer Company
  1938. //
  1939. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  1940. // Use is subject to license terms.
  1941. // Time expressed in seconds and nanoseconds
  1942. type Timespec = struct {
  1943. Ftv_sec int64
  1944. Ftv_nsec int64
  1945. } /* time_impl.h:57:9 */
  1946. // used by UFS
  1947. // END CSTYLED
  1948. // Nested include for BSD/sockets source compatibility.
  1949. // (The select macros used to be defined here).
  1950. // CDDL HEADER START
  1951. //
  1952. // The contents of this file are subject to the terms of the
  1953. // Common Development and Distribution License (the "License").
  1954. // You may not use this file except in compliance with the License.
  1955. //
  1956. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  1957. // or http://www.opensolaris.org/os/licensing.
  1958. // See the License for the specific language governing permissions
  1959. // and limitations under the License.
  1960. //
  1961. // When distributing Covered Code, include this CDDL HEADER in each
  1962. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  1963. // If applicable, add the following below this CDDL HEADER, with the
  1964. // fields enclosed by brackets "[]" replaced with your own identifying
  1965. // information: Portions Copyright [yyyy] [name of copyright owner]
  1966. //
  1967. // CDDL HEADER END
  1968. // Copyright 2014 Garrett D'Amore <garrett@damore.org>
  1969. //
  1970. // Copyright 2013 Nexenta Systems, Inc. All rights reserved.
  1971. //
  1972. // Copyright 2010 Sun Microsystems, Inc. All rights reserved.
  1973. // Use is subject to license terms.
  1974. // Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T
  1975. // All Rights Reserved
  1976. // University Copyright- Copyright (c) 1982, 1986, 1988
  1977. // The Regents of the University of California
  1978. // All Rights Reserved
  1979. //
  1980. // University Acknowledgment- Portions of this document are derived from
  1981. // software developed by the University of California, Berkeley, and its
  1982. // contributors.
  1983. // DO NOT EDIT THIS FILE.
  1984. //
  1985. // It has been auto-edited by fixincludes from:
  1986. //
  1987. // "/usr/include/sys/feature_tests.h"
  1988. //
  1989. // This had to be done to correct non-standard usages in the
  1990. // original, manufacturer supplied header file.
  1991. // CDDL HEADER START
  1992. //
  1993. // The contents of this file are subject to the terms of the
  1994. // Common Development and Distribution License (the "License").
  1995. // You may not use this file except in compliance with the License.
  1996. //
  1997. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  1998. // or http://www.opensolaris.org/os/licensing.
  1999. // See the License for the specific language governing permissions
  2000. // and limitations under the License.
  2001. //
  2002. // When distributing Covered Code, include this CDDL HEADER in each
  2003. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2004. // If applicable, add the following below this CDDL HEADER, with the
  2005. // fields enclosed by brackets "[]" replaced with your own identifying
  2006. // information: Portions Copyright [yyyy] [name of copyright owner]
  2007. //
  2008. // CDDL HEADER END
  2009. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  2010. // Copyright 2016 Joyent, Inc.
  2011. // Copyright 2022 Oxide Computer Company
  2012. //
  2013. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  2014. // Use is subject to license terms.
  2015. // CDDL HEADER START
  2016. //
  2017. // The contents of this file are subject to the terms of the
  2018. // Common Development and Distribution License, Version 1.0 only
  2019. // (the "License"). You may not use this file except in compliance
  2020. // with the License.
  2021. //
  2022. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2023. // or http://www.opensolaris.org/os/licensing.
  2024. // See the License for the specific language governing permissions
  2025. // and limitations under the License.
  2026. //
  2027. // When distributing Covered Code, include this CDDL HEADER in each
  2028. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2029. // If applicable, add the following below this CDDL HEADER, with the
  2030. // fields enclosed by brackets "[]" replaced with your own identifying
  2031. // information: Portions Copyright [yyyy] [name of copyright owner]
  2032. //
  2033. // CDDL HEADER END
  2034. // Copyright 2005 Sun Microsystems, Inc. All rights reserved.
  2035. // Use is subject to license terms.
  2036. // Implementation-private. This header should not be included
  2037. // directly by an application. The application should instead
  2038. // include <time.h> which includes this header conditionally
  2039. // depending on which feature test macros are defined. By default,
  2040. // this header is included by <time.h>. X/Open and POSIX
  2041. // standards requirements result in this header being included
  2042. // by <time.h> only under a restricted set of conditions.
  2043. // DO NOT EDIT THIS FILE.
  2044. //
  2045. // It has been auto-edited by fixincludes from:
  2046. //
  2047. // "/usr/include/sys/feature_tests.h"
  2048. //
  2049. // This had to be done to correct non-standard usages in the
  2050. // original, manufacturer supplied header file.
  2051. // CDDL HEADER START
  2052. //
  2053. // The contents of this file are subject to the terms of the
  2054. // Common Development and Distribution License (the "License").
  2055. // You may not use this file except in compliance with the License.
  2056. //
  2057. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2058. // or http://www.opensolaris.org/os/licensing.
  2059. // See the License for the specific language governing permissions
  2060. // and limitations under the License.
  2061. //
  2062. // When distributing Covered Code, include this CDDL HEADER in each
  2063. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2064. // If applicable, add the following below this CDDL HEADER, with the
  2065. // fields enclosed by brackets "[]" replaced with your own identifying
  2066. // information: Portions Copyright [yyyy] [name of copyright owner]
  2067. //
  2068. // CDDL HEADER END
  2069. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  2070. // Copyright 2016 Joyent, Inc.
  2071. // Copyright 2022 Oxide Computer Company
  2072. //
  2073. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  2074. // Use is subject to license terms.
  2075. // Time expressed in seconds and nanoseconds
  2076. type Timespec_t = Timespec /* time_impl.h:60:3 */
  2077. type Timestruc_t = Timespec /* time_impl.h:81:25 */ // definition per SVr4
  2078. // The following has been left in for backward compatibility. Portable
  2079. // applications should not use the structure name timestruc.
  2080. // Timer specification
  2081. type Itimerspec = struct {
  2082. Fit_interval struct {
  2083. Ftv_sec int64
  2084. Ftv_nsec int64
  2085. }
  2086. Fit_value struct {
  2087. Ftv_sec int64
  2088. Ftv_nsec int64
  2089. }
  2090. } /* time_impl.h:95:9 */
  2091. // definition per SVr4
  2092. // The following has been left in for backward compatibility. Portable
  2093. // applications should not use the structure name timestruc.
  2094. // Timer specification
  2095. type Itimerspec_t = Itimerspec /* time_impl.h:98:3 */
  2096. // Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T
  2097. // All Rights Reserved
  2098. // Copyright (c) 1982, 1986, 1993 Regents of the University of California.
  2099. // All rights reserved. The Berkeley software License Agreement
  2100. // specifies the terms and conditions for redistribution.
  2101. // Copyright 2014 Garrett D'Amore <garrett@damore.org>
  2102. //
  2103. // Copyright 2009 Sun Microsystems, Inc. All rights reserved.
  2104. // Use is subject to license terms.
  2105. //
  2106. // Copyright 2013 Nexenta Systems, Inc. All rights reserved.
  2107. // Copyright 2016 Joyent, Inc.
  2108. // Copyright 2020 OmniOS Community Edition (OmniOSce) Association.
  2109. // Copyright (c) 2013, 2016 by Delphix. All rights reserved.
  2110. // DO NOT EDIT THIS FILE.
  2111. //
  2112. // It has been auto-edited by fixincludes from:
  2113. //
  2114. // "/usr/include/sys/feature_tests.h"
  2115. //
  2116. // This had to be done to correct non-standard usages in the
  2117. // original, manufacturer supplied header file.
  2118. // CDDL HEADER START
  2119. //
  2120. // The contents of this file are subject to the terms of the
  2121. // Common Development and Distribution License (the "License").
  2122. // You may not use this file except in compliance with the License.
  2123. //
  2124. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2125. // or http://www.opensolaris.org/os/licensing.
  2126. // See the License for the specific language governing permissions
  2127. // and limitations under the License.
  2128. //
  2129. // When distributing Covered Code, include this CDDL HEADER in each
  2130. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2131. // If applicable, add the following below this CDDL HEADER, with the
  2132. // fields enclosed by brackets "[]" replaced with your own identifying
  2133. // information: Portions Copyright [yyyy] [name of copyright owner]
  2134. //
  2135. // CDDL HEADER END
  2136. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  2137. // Copyright 2016 Joyent, Inc.
  2138. // Copyright 2022 Oxide Computer Company
  2139. //
  2140. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  2141. // Use is subject to license terms.
  2142. // Structure returned by gettimeofday(2) system call,
  2143. // and used in other calls.
  2144. type Timeval = struct {
  2145. Ftv_sec int64
  2146. Ftv_usec int64
  2147. } /* time.h:54:1 */
  2148. type Timezone = struct {
  2149. Ftz_minuteswest int32
  2150. Ftz_dsttime int32
  2151. } /* time.h:86:1 */
  2152. // Needed for longlong_t type. Placement of this due to <sys/types.h>
  2153. // including <sys/select.h> which relies on the presense of the itimerval
  2154. // structure.
  2155. // CDDL HEADER START
  2156. //
  2157. // The contents of this file are subject to the terms of the
  2158. // Common Development and Distribution License (the "License").
  2159. // You may not use this file except in compliance with the License.
  2160. //
  2161. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2162. // or http://www.opensolaris.org/os/licensing.
  2163. // See the License for the specific language governing permissions
  2164. // and limitations under the License.
  2165. //
  2166. // When distributing Covered Code, include this CDDL HEADER in each
  2167. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2168. // If applicable, add the following below this CDDL HEADER, with the
  2169. // fields enclosed by brackets "[]" replaced with your own identifying
  2170. // information: Portions Copyright [yyyy] [name of copyright owner]
  2171. //
  2172. // CDDL HEADER END
  2173. // Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T
  2174. // All Rights Reserved
  2175. // Copyright 2009 Sun Microsystems, Inc. All rights reserved.
  2176. // Use is subject to license terms.
  2177. //
  2178. // Copyright 2013 Nexenta Systems, Inc. All rights reserved.
  2179. // Copyright 2016 Joyent, Inc.
  2180. // Copyright 2021 Oxide Computer Company
  2181. // Operations on timevals.
  2182. // Names of the interval timers, and structure
  2183. // defining a timer setting.
  2184. // time and when system is running on
  2185. // behalf of the process.
  2186. // time profiling of multithreaded
  2187. // programs.
  2188. type Itimerval = struct {
  2189. Fit_interval struct {
  2190. Ftv_sec int64
  2191. Ftv_usec int64
  2192. }
  2193. Fit_value struct {
  2194. Ftv_sec int64
  2195. Ftv_usec int64
  2196. }
  2197. } /* time.h:209:1 */
  2198. // Definitions for commonly used resolutions.
  2199. // Time expressed as a 64-bit nanosecond counter.
  2200. type Hrtime_t = int64 /* time.h:265:20 */
  2201. // The inclusion of <time.h> is historical and was added for
  2202. // backward compatibility in delta 1.2 when a number of definitions
  2203. // were moved out of <sys/time.h>. More recently, the timespec and
  2204. // itimerspec structure definitions, along with the _CLOCK_*, CLOCK_*,
  2205. // _TIMER_*, and TIMER_* symbols were moved to <sys/time_impl.h>,
  2206. // which is now included by <time.h>. This change was due to POSIX
  2207. // 1003.1b-1993 and X/Open UNIX 98 requirements. For non-POSIX and
  2208. // non-X/Open applications, including this header will still make
  2209. // visible these definitions.
  2210. // CDDL HEADER START
  2211. //
  2212. // The contents of this file are subject to the terms of the
  2213. // Common Development and Distribution License (the "License").
  2214. // You may not use this file except in compliance with the License.
  2215. //
  2216. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2217. // or http://www.opensolaris.org/os/licensing.
  2218. // See the License for the specific language governing permissions
  2219. // and limitations under the License.
  2220. //
  2221. // When distributing Covered Code, include this CDDL HEADER in each
  2222. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2223. // If applicable, add the following below this CDDL HEADER, with the
  2224. // fields enclosed by brackets "[]" replaced with your own identifying
  2225. // information: Portions Copyright [yyyy] [name of copyright owner]
  2226. //
  2227. // CDDL HEADER END
  2228. // Copyright (c) 1988 AT&T
  2229. // All Rights Reserved
  2230. // Copyright 2014 Garrett D'Amore <garrett@damore.org>
  2231. //
  2232. // Copyright 2007 Sun Microsystems, Inc. All rights reserved.
  2233. // Use is subject to license terms.
  2234. // Copyright 2010 Nexenta Systems, Inc. Al rights reserved.
  2235. // Copyright 2016 Joyent, Inc.
  2236. // DO NOT EDIT THIS FILE.
  2237. //
  2238. // It has been auto-edited by fixincludes from:
  2239. //
  2240. // "/usr/include/sys/feature_tests.h"
  2241. //
  2242. // This had to be done to correct non-standard usages in the
  2243. // original, manufacturer supplied header file.
  2244. // CDDL HEADER START
  2245. //
  2246. // The contents of this file are subject to the terms of the
  2247. // Common Development and Distribution License (the "License").
  2248. // You may not use this file except in compliance with the License.
  2249. //
  2250. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2251. // or http://www.opensolaris.org/os/licensing.
  2252. // See the License for the specific language governing permissions
  2253. // and limitations under the License.
  2254. //
  2255. // When distributing Covered Code, include this CDDL HEADER in each
  2256. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2257. // If applicable, add the following below this CDDL HEADER, with the
  2258. // fields enclosed by brackets "[]" replaced with your own identifying
  2259. // information: Portions Copyright [yyyy] [name of copyright owner]
  2260. //
  2261. // CDDL HEADER END
  2262. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  2263. // Copyright 2016 Joyent, Inc.
  2264. // Copyright 2022 Oxide Computer Company
  2265. //
  2266. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  2267. // Use is subject to license terms.
  2268. // CDDL HEADER START
  2269. //
  2270. // The contents of this file are subject to the terms of the
  2271. // Common Development and Distribution License, Version 1.0 only
  2272. // (the "License"). You may not use this file except in compliance
  2273. // with the License.
  2274. //
  2275. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2276. // or http://www.opensolaris.org/os/licensing.
  2277. // See the License for the specific language governing permissions
  2278. // and limitations under the License.
  2279. //
  2280. // When distributing Covered Code, include this CDDL HEADER in each
  2281. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2282. // If applicable, add the following below this CDDL HEADER, with the
  2283. // fields enclosed by brackets "[]" replaced with your own identifying
  2284. // information: Portions Copyright [yyyy] [name of copyright owner]
  2285. //
  2286. // CDDL HEADER END
  2287. // Copyright (c) 1988 AT&T
  2288. // All Rights Reserved
  2289. // Copyright 2014 Garrett D'Amore <garrett@damore.org>
  2290. // Copyright 2014 PALO, Richard.
  2291. //
  2292. // Copyright 2004 Sun Microsystems, Inc. All rights reserved.
  2293. // Use is subject to license terms.
  2294. // An application should not include this header directly. Instead it
  2295. // should be included only through the inclusion of other Sun headers.
  2296. //
  2297. // The contents of this header is limited to identifiers specified in the
  2298. // C Standard. Any new identifiers specified in future amendments to the
  2299. // C Standard must be placed in this header. If these new identifiers
  2300. // are required to also be in the C++ Standard "std" namespace, then for
  2301. // anything other than macro definitions, corresponding "using" directives
  2302. // must also be added to <time.h.h>.
  2303. // DO NOT EDIT THIS FILE.
  2304. //
  2305. // It has been auto-edited by fixincludes from:
  2306. //
  2307. // "/usr/include/sys/feature_tests.h"
  2308. //
  2309. // This had to be done to correct non-standard usages in the
  2310. // original, manufacturer supplied header file.
  2311. // CDDL HEADER START
  2312. //
  2313. // The contents of this file are subject to the terms of the
  2314. // Common Development and Distribution License (the "License").
  2315. // You may not use this file except in compliance with the License.
  2316. //
  2317. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2318. // or http://www.opensolaris.org/os/licensing.
  2319. // See the License for the specific language governing permissions
  2320. // and limitations under the License.
  2321. //
  2322. // When distributing Covered Code, include this CDDL HEADER in each
  2323. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2324. // If applicable, add the following below this CDDL HEADER, with the
  2325. // fields enclosed by brackets "[]" replaced with your own identifying
  2326. // information: Portions Copyright [yyyy] [name of copyright owner]
  2327. //
  2328. // CDDL HEADER END
  2329. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  2330. // Copyright 2016 Joyent, Inc.
  2331. // Copyright 2022 Oxide Computer Company
  2332. //
  2333. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  2334. // Use is subject to license terms.
  2335. // This file and its contents are supplied under the terms of the
  2336. // Common Development and Distribution License ("CDDL"), version 1.0.
  2337. // You may only use this file in accordance with the terms of version
  2338. // 1.0 of the CDDL.
  2339. //
  2340. // A full copy of the text of the CDDL should have accompanied this
  2341. // source. A copy of the CDDL is also available via the Internet at
  2342. // http://www.illumos.org/license/CDDL.
  2343. // Copyright 2014-2016 PALO, Richard.
  2344. // DO NOT EDIT THIS FILE.
  2345. //
  2346. // It has been auto-edited by fixincludes from:
  2347. //
  2348. // "/usr/include/sys/feature_tests.h"
  2349. //
  2350. // This had to be done to correct non-standard usages in the
  2351. // original, manufacturer supplied header file.
  2352. // CDDL HEADER START
  2353. //
  2354. // The contents of this file are subject to the terms of the
  2355. // Common Development and Distribution License (the "License").
  2356. // You may not use this file except in compliance with the License.
  2357. //
  2358. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2359. // or http://www.opensolaris.org/os/licensing.
  2360. // See the License for the specific language governing permissions
  2361. // and limitations under the License.
  2362. //
  2363. // When distributing Covered Code, include this CDDL HEADER in each
  2364. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2365. // If applicable, add the following below this CDDL HEADER, with the
  2366. // fields enclosed by brackets "[]" replaced with your own identifying
  2367. // information: Portions Copyright [yyyy] [name of copyright owner]
  2368. //
  2369. // CDDL HEADER END
  2370. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  2371. // Copyright 2016 Joyent, Inc.
  2372. // Copyright 2022 Oxide Computer Company
  2373. //
  2374. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  2375. // Use is subject to license terms.
  2376. // POSIX.1-2008 requires that the NULL macro be cast to type void *.
  2377. type Tm = struct {
  2378. Ftm_sec int32
  2379. Ftm_min int32
  2380. Ftm_hour int32
  2381. Ftm_mday int32
  2382. Ftm_mon int32
  2383. Ftm_year int32
  2384. Ftm_wday int32
  2385. Ftm_yday int32
  2386. Ftm_isdst int32
  2387. } /* time_iso.h:80:1 */
  2388. // Neither X/Open nor POSIX allow the inclusion of <signal.h> for the
  2389. // definition of the sigevent structure. Both require the inclusion
  2390. // of <signal.h> and <time.h> when using the timer_create() function.
  2391. // However, X/Open also specifies that the sigevent structure be defined
  2392. // in <time.h> as described in the header <signal.h>. This prevents
  2393. // compiler warnings for applications that only include <time.h> and not
  2394. // also <signal.h>. The sigval union and the sigevent structure is
  2395. // therefore defined both here and in <sys/siginfo.h> which gets included
  2396. // via inclusion of <signal.h>.
  2397. type Sigval = struct {
  2398. F__ccgo_pad1 [0]uint64
  2399. Fsival_int int32
  2400. F__ccgo_pad2 [4]byte
  2401. } /* time.h:125:1 */
  2402. type Sigevent = struct {
  2403. Fsigev_notify int32
  2404. Fsigev_signo int32
  2405. Fsigev_value struct {
  2406. F__ccgo_pad1 [0]uint64
  2407. Fsival_int int32
  2408. F__ccgo_pad2 [4]byte
  2409. }
  2410. Fsigev_notify_function uintptr
  2411. Fsigev_notify_attributes uintptr
  2412. F__sigev_pad2 int32
  2413. F__ccgo_pad1 [4]byte
  2414. } /* time.h:133:1 */
  2415. type Locale_t = uintptr /* time.h:292:24 */
  2416. // The inclusion of <sys/select.h> is needed for the FD_CLR,
  2417. // FD_ISSET, FD_SET, and FD_SETSIZE macros as well as the
  2418. // select() prototype defined in the XOpen specifications
  2419. // beginning with XSH4v2. Placement required after definition
  2420. // for itimerval.
  2421. // CDDL HEADER START
  2422. //
  2423. // The contents of this file are subject to the terms of the
  2424. // Common Development and Distribution License (the "License").
  2425. // You may not use this file except in compliance with the License.
  2426. //
  2427. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2428. // or http://www.opensolaris.org/os/licensing.
  2429. // See the License for the specific language governing permissions
  2430. // and limitations under the License.
  2431. //
  2432. // When distributing Covered Code, include this CDDL HEADER in each
  2433. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2434. // If applicable, add the following below this CDDL HEADER, with the
  2435. // fields enclosed by brackets "[]" replaced with your own identifying
  2436. // information: Portions Copyright [yyyy] [name of copyright owner]
  2437. //
  2438. // CDDL HEADER END
  2439. // Copyright 2014 Garrett D'Amore <garrett@damore.org>
  2440. //
  2441. // Copyright 2013 Nexenta Systems, Inc. All rights reserved.
  2442. //
  2443. // Copyright 2010 Sun Microsystems, Inc. All rights reserved.
  2444. // Use is subject to license terms.
  2445. // Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T
  2446. // All Rights Reserved
  2447. // University Copyright- Copyright (c) 1982, 1986, 1988
  2448. // The Regents of the University of California
  2449. // All Rights Reserved
  2450. //
  2451. // University Acknowledgment- Portions of this document are derived from
  2452. // software developed by the University of California, Berkeley, and its
  2453. // contributors.
  2454. // The sigset_t type is defined in <sys/signal.h> and duplicated
  2455. // in <sys/ucontext.h> as a result of XPG4v2 requirements. XPG6
  2456. // now allows the visibility of signal.h in this header, however
  2457. // an order of inclusion problem occurs as a result of inclusion
  2458. // of <sys/select.h> in <signal.h> under certain conditions.
  2459. // Rather than include <sys/signal.h> here, we've duplicated
  2460. // the sigset_t type instead. This type is required for the XPG6
  2461. // introduced pselect() function also declared in this header.
  2462. type Sigset_t = struct{ F__sigbits [4]uint32 } /* select.h:76:3 */
  2463. // Select uses bit masks of file descriptors in longs.
  2464. // These macros manipulate such bit fields.
  2465. // FD_SETSIZE may be defined by the user, but the default here
  2466. // should be >= RLIM_FD_MAX.
  2467. type Fd_mask = int64 /* select.h:92:14 */
  2468. type Fds_mask = int64 /* select.h:94:14 */
  2469. // The value of _NBBY needs to be consistant with the value
  2470. // of NBBY in <sys/param.h>.
  2471. type Fd_set1 = struct{ Ffds_bits [1024]int64 } /* select.h:120:9 */
  2472. // The value of _NBBY needs to be consistant with the value
  2473. // of NBBY in <sys/param.h>.
  2474. type Fd_set = Fd_set1 /* select.h:125:3 */
  2475. // _VOID was defined to be either void or char but this is not
  2476. // required because previous SunOS compilers have accepted the void
  2477. // type. However, because many system header and source files use the
  2478. // void keyword, the volatile keyword, and ANSI C function prototypes,
  2479. // non-ANSI compilers cannot compile the system anyway. The _VOID macro
  2480. // should therefore not be used and remains for source compatibility
  2481. // only.
  2482. // CSTYLED
  2483. // CDDL HEADER START
  2484. //
  2485. // The contents of this file are subject to the terms of the
  2486. // Common Development and Distribution License (the "License").
  2487. // You may not use this file except in compliance with the License.
  2488. //
  2489. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2490. // or http://www.opensolaris.org/os/licensing.
  2491. // See the License for the specific language governing permissions
  2492. // and limitations under the License.
  2493. //
  2494. // When distributing Covered Code, include this CDDL HEADER in each
  2495. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2496. // If applicable, add the following below this CDDL HEADER, with the
  2497. // fields enclosed by brackets "[]" replaced with your own identifying
  2498. // information: Portions Copyright [yyyy] [name of copyright owner]
  2499. //
  2500. // CDDL HEADER END
  2501. // Copyright 2014 Garrett D'Amore <garrett@damore.org>
  2502. // Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved.
  2503. // Copyright (c) 1990, 1991 UNIX System Laboratories, Inc.
  2504. // Copyright (c) 1984, 1986, 1987, 1988, 1989, 1990 AT&T
  2505. // All Rights Reserved
  2506. // DO NOT EDIT THIS FILE.
  2507. //
  2508. // It has been auto-edited by fixincludes from:
  2509. //
  2510. // "/usr/include/sys/feature_tests.h"
  2511. //
  2512. // This had to be done to correct non-standard usages in the
  2513. // original, manufacturer supplied header file.
  2514. // CDDL HEADER START
  2515. //
  2516. // The contents of this file are subject to the terms of the
  2517. // Common Development and Distribution License (the "License").
  2518. // You may not use this file except in compliance with the License.
  2519. //
  2520. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2521. // or http://www.opensolaris.org/os/licensing.
  2522. // See the License for the specific language governing permissions
  2523. // and limitations under the License.
  2524. //
  2525. // When distributing Covered Code, include this CDDL HEADER in each
  2526. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2527. // If applicable, add the following below this CDDL HEADER, with the
  2528. // fields enclosed by brackets "[]" replaced with your own identifying
  2529. // information: Portions Copyright [yyyy] [name of copyright owner]
  2530. //
  2531. // CDDL HEADER END
  2532. // Copyright 2013 Garrett D'Amore <garrett@damore.org>
  2533. // Copyright 2016 Joyent, Inc.
  2534. // Copyright 2022 Oxide Computer Company
  2535. //
  2536. // Copyright 2006 Sun Microsystems, Inc. All rights reserved.
  2537. // Use is subject to license terms.
  2538. // CDDL HEADER START
  2539. //
  2540. // The contents of this file are subject to the terms of the
  2541. // Common Development and Distribution License (the "License").
  2542. // You may not use this file except in compliance with the License.
  2543. //
  2544. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2545. // or http://www.opensolaris.org/os/licensing.
  2546. // See the License for the specific language governing permissions
  2547. // and limitations under the License.
  2548. //
  2549. // When distributing Covered Code, include this CDDL HEADER in each
  2550. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2551. // If applicable, add the following below this CDDL HEADER, with the
  2552. // fields enclosed by brackets "[]" replaced with your own identifying
  2553. // information: Portions Copyright [yyyy] [name of copyright owner]
  2554. //
  2555. // CDDL HEADER END
  2556. // Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T
  2557. // All Rights Reserved
  2558. // Copyright 2009 Sun Microsystems, Inc. All rights reserved.
  2559. // Use is subject to license terms.
  2560. //
  2561. // Copyright 2013 Nexenta Systems, Inc. All rights reserved.
  2562. // Copyright 2016 Joyent, Inc.
  2563. // Copyright 2021 Oxide Computer Company
  2564. // The implementation specific header <sys/time_impl.h> includes a
  2565. // definition for timestruc_t needed by the stat structure. However,
  2566. // including either <time.h>, which includes <sys/time_impl.h>, or
  2567. // including <sys/time_impl.h> directly will break both X/Open and
  2568. // POSIX namespace. Preceeding tag, structure, and structure member
  2569. // names with underscores eliminates the namespace breakage and at the
  2570. // same time, with unique type names, eliminates the possibility of
  2571. // timespec_t or timestruct_t naming conflicts that could otherwise
  2572. // result based on the order of inclusion of <sys/stat.h> and
  2573. // <sys/time.h>. The header <sys/time_std_impl.h> contains the
  2574. // standards namespace safe versions of these definitions.
  2575. // CDDL HEADER START
  2576. //
  2577. // The contents of this file are subject to the terms of the
  2578. // Common Development and Distribution License, Version 1.0 only
  2579. // (the "License"). You may not use this file except in compliance
  2580. // with the License.
  2581. //
  2582. // You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  2583. // or http://www.opensolaris.org/os/licensing.
  2584. // See the License for the specific language governing permissions
  2585. // and limitations under the License.
  2586. //
  2587. // When distributing Covered Code, include this CDDL HEADER in each
  2588. // file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  2589. // If applicable, add the following below this CDDL HEADER, with the
  2590. // fields enclosed by brackets "[]" replaced with your own identifying
  2591. // information: Portions Copyright [yyyy] [name of copyright owner]
  2592. //
  2593. // CDDL HEADER END
  2594. // Copyright 2005 Sun Microsystems, Inc. All rights reserved.
  2595. // Use is subject to license terms.
  2596. // Implementation-private. This header should not be included
  2597. // directly by an application. The application should instead
  2598. // include <time.h> which includes this header conditionally
  2599. // depending on which feature test macros are defined. By default,
  2600. // this header is included by <time.h>. X/Open and POSIX
  2601. // standards requirements result in this header being included
  2602. // by <time.h> only under a restricted set of conditions.
  2603. // stat structure, used by stat(2) and fstat(2)
  2604. // large file compilation environment setup
  2605. // In the LP64 compilation environment, map large file interfaces
  2606. // back to native versions where possible.
  2607. // User level stat structure definitions.
  2608. type Stat = struct {
  2609. Fst_dev uint64
  2610. Fst_ino uint64
  2611. Fst_mode uint32
  2612. Fst_nlink uint32
  2613. Fst_uid uint32
  2614. Fst_gid uint32
  2615. Fst_rdev uint64
  2616. Fst_size int64
  2617. Fst_atim Timestruc_t
  2618. Fst_mtim Timestruc_t
  2619. Fst_ctim Timestruc_t
  2620. Fst_blksize int32
  2621. F__ccgo_pad1 [4]byte
  2622. Fst_blocks int64
  2623. Fst_fstype [16]int8
  2624. } /* stat.h:217:1 */
  2625. // transitional large file interface version
  2626. type Stat64 = struct {
  2627. Fst_dev uint64
  2628. Fst_ino uint64
  2629. Fst_mode uint32
  2630. Fst_nlink uint32
  2631. Fst_uid uint32
  2632. Fst_gid uint32
  2633. Fst_rdev uint64
  2634. Fst_size int64
  2635. Fst_atim Timestruc_t
  2636. Fst_mtim Timestruc_t
  2637. Fst_ctim Timestruc_t
  2638. Fst_blksize int32
  2639. F__ccgo_pad1 [4]byte
  2640. Fst_blocks int64
  2641. Fst_fstype [16]int8
  2642. } /* stat.h:278:1 */
  2643. // Copyright (c) 1989, 1993
  2644. // The Regents of the University of California. All rights reserved.
  2645. //
  2646. // Redistribution and use in source and binary forms, with or without
  2647. // modification, are permitted provided that the following conditions
  2648. // are met:
  2649. // 1. Redistributions of source code must retain the above copyright
  2650. // notice, this list of conditions and the following disclaimer.
  2651. // 2. Redistributions in binary form must reproduce the above copyright
  2652. // notice, this list of conditions and the following disclaimer in the
  2653. // documentation and/or other materials provided with the distribution.
  2654. // 3. Neither the name of the University nor the names of its contributors
  2655. // may be used to endorse or promote products derived from this software
  2656. // without specific prior written permission.
  2657. //
  2658. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2659. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2660. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2661. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2662. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2663. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2664. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2665. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2666. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2667. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2668. // SUCH DAMAGE.
  2669. type X_ftsent = struct {
  2670. Ffts_cycle uintptr
  2671. Ffts_parent uintptr
  2672. Ffts_link uintptr
  2673. Ffts_number int64
  2674. Ffts_pointer uintptr
  2675. Ffts_accpath uintptr
  2676. Ffts_path uintptr
  2677. Ffts_errno int32
  2678. Ffts_symfd int32
  2679. Ffts_pathlen uint64
  2680. Ffts_namelen uint64
  2681. Ffts_ino uint64
  2682. Ffts_dev uint64
  2683. Ffts_nlink uint32
  2684. Ffts_level int32
  2685. Ffts_info uint16
  2686. Ffts_flags uint16
  2687. Ffts_instr uint16
  2688. Ffts_spare uint16
  2689. Ffts_statp uintptr
  2690. Ffts_name [1]int8
  2691. F__ccgo_pad1 [7]byte
  2692. } /* fts.h:38:2 */
  2693. // Copyright (c) 1989, 1993
  2694. // The Regents of the University of California. All rights reserved.
  2695. //
  2696. // Redistribution and use in source and binary forms, with or without
  2697. // modification, are permitted provided that the following conditions
  2698. // are met:
  2699. // 1. Redistributions of source code must retain the above copyright
  2700. // notice, this list of conditions and the following disclaimer.
  2701. // 2. Redistributions in binary form must reproduce the above copyright
  2702. // notice, this list of conditions and the following disclaimer in the
  2703. // documentation and/or other materials provided with the distribution.
  2704. // 3. Neither the name of the University nor the names of its contributors
  2705. // may be used to endorse or promote products derived from this software
  2706. // without specific prior written permission.
  2707. //
  2708. // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2709. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2710. // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2711. // ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2712. // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2713. // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2714. // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2715. // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2716. // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2717. // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2718. // SUCH DAMAGE.
  2719. type FTS = struct {
  2720. Ffts_cur uintptr
  2721. Ffts_child uintptr
  2722. Ffts_array uintptr
  2723. Ffts_dev uint64
  2724. Ffts_path uintptr
  2725. Ffts_rfd int32
  2726. F__ccgo_pad1 [4]byte
  2727. Ffts_pathlen uint64
  2728. Ffts_nitems int32
  2729. F__ccgo_pad2 [4]byte
  2730. Ffts_compar uintptr
  2731. Ffts_options int32
  2732. F__ccgo_pad3 [4]byte
  2733. } /* fts.h:60:3 */
  2734. type FTSENT = X_ftsent /* fts.h:113:3 */
  2735. var _ int8 /* gen.c:5:13: */