triton-windows 3.5.0.post21__cp314-cp314-win_amd64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of triton-windows might be problematic. Click here for more details.

Files changed (217) hide show
  1. triton/_C/libtriton.pyd +0 -0
  2. triton/__init__.py +82 -0
  3. triton/_filecheck.py +97 -0
  4. triton/_internal_testing.py +255 -0
  5. triton/_utils.py +126 -0
  6. triton/backends/__init__.py +47 -0
  7. triton/backends/amd/__init__.py +0 -0
  8. triton/backends/amd/compiler.py +461 -0
  9. triton/backends/amd/driver.c +283 -0
  10. triton/backends/amd/driver.py +724 -0
  11. triton/backends/amd/lib/asanrtl.bc +0 -0
  12. triton/backends/amd/lib/ockl.bc +0 -0
  13. triton/backends/amd/lib/ocml.bc +0 -0
  14. triton/backends/compiler.py +90 -0
  15. triton/backends/driver.py +66 -0
  16. triton/backends/nvidia/__init__.py +0 -0
  17. triton/backends/nvidia/bin/ptxas.exe +0 -0
  18. triton/backends/nvidia/compiler.py +533 -0
  19. triton/backends/nvidia/driver.c +517 -0
  20. triton/backends/nvidia/driver.py +799 -0
  21. triton/backends/nvidia/include/cuda.h +26280 -0
  22. triton/backends/nvidia/lib/libdevice.10.bc +0 -0
  23. triton/backends/nvidia/lib/x64/cuda.lib +0 -0
  24. triton/compiler/__init__.py +7 -0
  25. triton/compiler/code_generator.py +1614 -0
  26. triton/compiler/compiler.py +509 -0
  27. triton/compiler/errors.py +51 -0
  28. triton/compiler/make_launcher.py +0 -0
  29. triton/errors.py +5 -0
  30. triton/experimental/__init__.py +0 -0
  31. triton/experimental/gluon/__init__.py +5 -0
  32. triton/experimental/gluon/_compiler.py +0 -0
  33. triton/experimental/gluon/_runtime.py +102 -0
  34. triton/experimental/gluon/language/__init__.py +119 -0
  35. triton/experimental/gluon/language/_core.py +490 -0
  36. triton/experimental/gluon/language/_layouts.py +583 -0
  37. triton/experimental/gluon/language/_math.py +20 -0
  38. triton/experimental/gluon/language/_semantic.py +380 -0
  39. triton/experimental/gluon/language/_standard.py +80 -0
  40. triton/experimental/gluon/language/amd/__init__.py +4 -0
  41. triton/experimental/gluon/language/amd/_layouts.py +96 -0
  42. triton/experimental/gluon/language/amd/cdna3/__init__.py +100 -0
  43. triton/experimental/gluon/language/amd/cdna4/__init__.py +48 -0
  44. triton/experimental/gluon/language/amd/cdna4/async_copy.py +151 -0
  45. triton/experimental/gluon/language/extra/__init__.py +3 -0
  46. triton/experimental/gluon/language/nvidia/__init__.py +4 -0
  47. triton/experimental/gluon/language/nvidia/ampere/__init__.py +3 -0
  48. triton/experimental/gluon/language/nvidia/ampere/async_copy.py +74 -0
  49. triton/experimental/gluon/language/nvidia/ampere/mbarrier.py +80 -0
  50. triton/experimental/gluon/language/nvidia/blackwell/__init__.py +387 -0
  51. triton/experimental/gluon/language/nvidia/blackwell/tma.py +52 -0
  52. triton/experimental/gluon/language/nvidia/hopper/__init__.py +132 -0
  53. triton/experimental/gluon/language/nvidia/hopper/mbarrier.py +34 -0
  54. triton/experimental/gluon/language/nvidia/hopper/tma.py +97 -0
  55. triton/experimental/gluon/nvidia/__init__.py +4 -0
  56. triton/experimental/gluon/nvidia/blackwell.py +3 -0
  57. triton/experimental/gluon/nvidia/hopper.py +45 -0
  58. triton/knobs.py +546 -0
  59. triton/language/__init__.py +342 -0
  60. triton/language/core.py +3405 -0
  61. triton/language/extra/__init__.py +26 -0
  62. triton/language/extra/cuda/__init__.py +16 -0
  63. triton/language/extra/cuda/gdc.py +42 -0
  64. triton/language/extra/cuda/libdevice.py +1629 -0
  65. triton/language/extra/cuda/utils.py +109 -0
  66. triton/language/extra/hip/__init__.py +5 -0
  67. triton/language/extra/hip/libdevice.py +491 -0
  68. triton/language/extra/hip/utils.py +35 -0
  69. triton/language/extra/libdevice.py +790 -0
  70. triton/language/math.py +249 -0
  71. triton/language/random.py +218 -0
  72. triton/language/semantic.py +1939 -0
  73. triton/language/standard.py +534 -0
  74. triton/language/target_info.py +54 -0
  75. triton/runtime/__init__.py +23 -0
  76. triton/runtime/_allocation.py +44 -0
  77. triton/runtime/_async_compile.py +55 -0
  78. triton/runtime/autotuner.py +476 -0
  79. triton/runtime/build.py +168 -0
  80. triton/runtime/cache.py +317 -0
  81. triton/runtime/driver.py +38 -0
  82. triton/runtime/errors.py +36 -0
  83. triton/runtime/interpreter.py +1414 -0
  84. triton/runtime/jit.py +1107 -0
  85. triton/runtime/tcc/include/_mingw.h +168 -0
  86. triton/runtime/tcc/include/assert.h +62 -0
  87. triton/runtime/tcc/include/conio.h +409 -0
  88. triton/runtime/tcc/include/ctype.h +281 -0
  89. triton/runtime/tcc/include/dir.h +31 -0
  90. triton/runtime/tcc/include/direct.h +68 -0
  91. triton/runtime/tcc/include/dirent.h +135 -0
  92. triton/runtime/tcc/include/dos.h +55 -0
  93. triton/runtime/tcc/include/errno.h +75 -0
  94. triton/runtime/tcc/include/excpt.h +123 -0
  95. triton/runtime/tcc/include/fcntl.h +52 -0
  96. triton/runtime/tcc/include/fenv.h +108 -0
  97. triton/runtime/tcc/include/float.h +75 -0
  98. triton/runtime/tcc/include/inttypes.h +297 -0
  99. triton/runtime/tcc/include/io.h +418 -0
  100. triton/runtime/tcc/include/iso646.h +36 -0
  101. triton/runtime/tcc/include/limits.h +116 -0
  102. triton/runtime/tcc/include/locale.h +91 -0
  103. triton/runtime/tcc/include/malloc.h +181 -0
  104. triton/runtime/tcc/include/math.h +497 -0
  105. triton/runtime/tcc/include/mem.h +13 -0
  106. triton/runtime/tcc/include/memory.h +40 -0
  107. triton/runtime/tcc/include/process.h +176 -0
  108. triton/runtime/tcc/include/sec_api/conio_s.h +42 -0
  109. triton/runtime/tcc/include/sec_api/crtdbg_s.h +19 -0
  110. triton/runtime/tcc/include/sec_api/io_s.h +33 -0
  111. triton/runtime/tcc/include/sec_api/mbstring_s.h +52 -0
  112. triton/runtime/tcc/include/sec_api/search_s.h +25 -0
  113. triton/runtime/tcc/include/sec_api/stdio_s.h +145 -0
  114. triton/runtime/tcc/include/sec_api/stdlib_s.h +67 -0
  115. triton/runtime/tcc/include/sec_api/stralign_s.h +30 -0
  116. triton/runtime/tcc/include/sec_api/string_s.h +41 -0
  117. triton/runtime/tcc/include/sec_api/sys/timeb_s.h +34 -0
  118. triton/runtime/tcc/include/sec_api/tchar_s.h +266 -0
  119. triton/runtime/tcc/include/sec_api/time_s.h +61 -0
  120. triton/runtime/tcc/include/sec_api/wchar_s.h +128 -0
  121. triton/runtime/tcc/include/setjmp.h +160 -0
  122. triton/runtime/tcc/include/share.h +28 -0
  123. triton/runtime/tcc/include/signal.h +63 -0
  124. triton/runtime/tcc/include/stdalign.h +16 -0
  125. triton/runtime/tcc/include/stdarg.h +14 -0
  126. triton/runtime/tcc/include/stdatomic.h +171 -0
  127. triton/runtime/tcc/include/stdbool.h +11 -0
  128. triton/runtime/tcc/include/stddef.h +42 -0
  129. triton/runtime/tcc/include/stdint.h +212 -0
  130. triton/runtime/tcc/include/stdio.h +429 -0
  131. triton/runtime/tcc/include/stdlib.h +591 -0
  132. triton/runtime/tcc/include/stdnoreturn.h +7 -0
  133. triton/runtime/tcc/include/string.h +164 -0
  134. triton/runtime/tcc/include/sys/fcntl.h +13 -0
  135. triton/runtime/tcc/include/sys/file.h +14 -0
  136. triton/runtime/tcc/include/sys/locking.h +30 -0
  137. triton/runtime/tcc/include/sys/stat.h +290 -0
  138. triton/runtime/tcc/include/sys/time.h +69 -0
  139. triton/runtime/tcc/include/sys/timeb.h +133 -0
  140. triton/runtime/tcc/include/sys/types.h +123 -0
  141. triton/runtime/tcc/include/sys/unistd.h +14 -0
  142. triton/runtime/tcc/include/sys/utime.h +146 -0
  143. triton/runtime/tcc/include/tcc/tcc_libm.h +618 -0
  144. triton/runtime/tcc/include/tccdefs.h +342 -0
  145. triton/runtime/tcc/include/tcclib.h +80 -0
  146. triton/runtime/tcc/include/tchar.h +1102 -0
  147. triton/runtime/tcc/include/tgmath.h +89 -0
  148. triton/runtime/tcc/include/time.h +287 -0
  149. triton/runtime/tcc/include/uchar.h +33 -0
  150. triton/runtime/tcc/include/unistd.h +1 -0
  151. triton/runtime/tcc/include/vadefs.h +11 -0
  152. triton/runtime/tcc/include/values.h +4 -0
  153. triton/runtime/tcc/include/varargs.h +12 -0
  154. triton/runtime/tcc/include/wchar.h +873 -0
  155. triton/runtime/tcc/include/wctype.h +172 -0
  156. triton/runtime/tcc/include/winapi/basetsd.h +149 -0
  157. triton/runtime/tcc/include/winapi/basetyps.h +85 -0
  158. triton/runtime/tcc/include/winapi/guiddef.h +156 -0
  159. triton/runtime/tcc/include/winapi/poppack.h +8 -0
  160. triton/runtime/tcc/include/winapi/pshpack1.h +8 -0
  161. triton/runtime/tcc/include/winapi/pshpack2.h +8 -0
  162. triton/runtime/tcc/include/winapi/pshpack4.h +8 -0
  163. triton/runtime/tcc/include/winapi/pshpack8.h +8 -0
  164. triton/runtime/tcc/include/winapi/qos.h +72 -0
  165. triton/runtime/tcc/include/winapi/shellapi.h +59 -0
  166. triton/runtime/tcc/include/winapi/winbase.h +2958 -0
  167. triton/runtime/tcc/include/winapi/wincon.h +309 -0
  168. triton/runtime/tcc/include/winapi/windef.h +293 -0
  169. triton/runtime/tcc/include/winapi/windows.h +127 -0
  170. triton/runtime/tcc/include/winapi/winerror.h +3166 -0
  171. triton/runtime/tcc/include/winapi/wingdi.h +4080 -0
  172. triton/runtime/tcc/include/winapi/winnls.h +778 -0
  173. triton/runtime/tcc/include/winapi/winnt.h +5837 -0
  174. triton/runtime/tcc/include/winapi/winreg.h +272 -0
  175. triton/runtime/tcc/include/winapi/winsock2.h +1474 -0
  176. triton/runtime/tcc/include/winapi/winuser.h +5651 -0
  177. triton/runtime/tcc/include/winapi/winver.h +160 -0
  178. triton/runtime/tcc/include/winapi/ws2ipdef.h +21 -0
  179. triton/runtime/tcc/include/winapi/ws2tcpip.h +391 -0
  180. triton/runtime/tcc/lib/cuda.def +697 -0
  181. triton/runtime/tcc/lib/gdi32.def +337 -0
  182. triton/runtime/tcc/lib/kernel32.def +770 -0
  183. triton/runtime/tcc/lib/libtcc1.a +0 -0
  184. triton/runtime/tcc/lib/msvcrt.def +1399 -0
  185. triton/runtime/tcc/lib/python3.def +810 -0
  186. triton/runtime/tcc/lib/python310.def +1610 -0
  187. triton/runtime/tcc/lib/python311.def +1633 -0
  188. triton/runtime/tcc/lib/python312.def +1703 -0
  189. triton/runtime/tcc/lib/python313.def +1651 -0
  190. triton/runtime/tcc/lib/python313t.def +1656 -0
  191. triton/runtime/tcc/lib/python314.def +1800 -0
  192. triton/runtime/tcc/lib/python314t.def +1809 -0
  193. triton/runtime/tcc/lib/python39.def +1644 -0
  194. triton/runtime/tcc/lib/python3t.def +905 -0
  195. triton/runtime/tcc/lib/user32.def +658 -0
  196. triton/runtime/tcc/libtcc.dll +0 -0
  197. triton/runtime/tcc/tcc.exe +0 -0
  198. triton/testing.py +543 -0
  199. triton/tools/__init__.py +0 -0
  200. triton/tools/build_extern.py +365 -0
  201. triton/tools/compile.py +210 -0
  202. triton/tools/disasm.py +143 -0
  203. triton/tools/extra/cuda/compile.c +70 -0
  204. triton/tools/extra/cuda/compile.h +14 -0
  205. triton/tools/extra/hip/compile.cpp +66 -0
  206. triton/tools/extra/hip/compile.h +13 -0
  207. triton/tools/link.py +322 -0
  208. triton/tools/mxfp.py +301 -0
  209. triton/tools/ragged_tma.py +92 -0
  210. triton/tools/tensor_descriptor.py +34 -0
  211. triton/windows_utils.py +405 -0
  212. triton_windows-3.5.0.post21.dist-info/METADATA +46 -0
  213. triton_windows-3.5.0.post21.dist-info/RECORD +217 -0
  214. triton_windows-3.5.0.post21.dist-info/WHEEL +5 -0
  215. triton_windows-3.5.0.post21.dist-info/entry_points.txt +3 -0
  216. triton_windows-3.5.0.post21.dist-info/licenses/LICENSE +23 -0
  217. triton_windows-3.5.0.post21.dist-info/top_level.txt +1 -0
@@ -0,0 +1,418 @@
1
+
2
+ /**
3
+ * This file has no copyright assigned and is placed in the Public Domain.
4
+ * This file is part of the w64 mingw-runtime package.
5
+ * No warranty is given; refer to the file DISCLAIMER within this package.
6
+ */
7
+ #ifndef _IO_H_
8
+ #define _IO_H_
9
+
10
+ #include <_mingw.h>
11
+ #include <string.h>
12
+
13
+ #pragma pack(push,_CRT_PACKING)
14
+
15
+ #ifndef _POSIX_
16
+
17
+ #ifdef __cplusplus
18
+ extern "C" {
19
+ #endif
20
+
21
+ _CRTIMP char* __cdecl _getcwd (char*, int);
22
+ #ifndef _FSIZE_T_DEFINED
23
+ typedef unsigned long _fsize_t;
24
+ #define _FSIZE_T_DEFINED
25
+ #endif
26
+
27
+ #ifndef _FINDDATA_T_DEFINED
28
+
29
+ struct _finddata32_t {
30
+ unsigned attrib;
31
+ __time32_t time_create;
32
+ __time32_t time_access;
33
+ __time32_t time_write;
34
+ _fsize_t size;
35
+ char name[260];
36
+ };
37
+
38
+ /*#if _INTEGRAL_MAX_BITS >= 64*/
39
+
40
+ struct _finddata32i64_t {
41
+ unsigned attrib;
42
+ __time32_t time_create;
43
+ __time32_t time_access;
44
+ __time32_t time_write;
45
+ __int64 size;
46
+ char name[260];
47
+ };
48
+
49
+ struct _finddata64i32_t {
50
+ unsigned attrib;
51
+ __time64_t time_create;
52
+ __time64_t time_access;
53
+ __time64_t time_write;
54
+ _fsize_t size;
55
+ char name[260];
56
+ };
57
+
58
+ struct __finddata64_t {
59
+ unsigned attrib;
60
+ __time64_t time_create;
61
+ __time64_t time_access;
62
+ __time64_t time_write;
63
+ __int64 size;
64
+ char name[260];
65
+ };
66
+ /* #endif */
67
+
68
+ #ifdef _USE_32BIT_TIME_T
69
+ #define _finddata_t _finddata32_t
70
+ #define _finddatai64_t _finddata32i64_t
71
+
72
+ #ifdef _WIN64
73
+ #define _findfirst _findfirst32
74
+ #define _findnext _findnext32
75
+ #else
76
+ #define _findfirst32 _findfirst
77
+ #define _findnext32 _findnext
78
+ #endif
79
+ #define _findfirsti64 _findfirst32i64
80
+ #define _findnexti64 _findnext32i64
81
+ #else
82
+ #define _finddata_t _finddata64i32_t
83
+ #define _finddatai64_t __finddata64_t
84
+
85
+ #define _findfirst _findfirst64i32
86
+ #define _findnext _findnext64i32
87
+ #define _findfirsti64 _findfirst64
88
+ #define _findnexti64 _findnext64
89
+ #endif
90
+
91
+ #define _FINDDATA_T_DEFINED
92
+ #endif
93
+
94
+ #ifndef _WFINDDATA_T_DEFINED
95
+
96
+ struct _wfinddata32_t {
97
+ unsigned attrib;
98
+ __time32_t time_create;
99
+ __time32_t time_access;
100
+ __time32_t time_write;
101
+ _fsize_t size;
102
+ wchar_t name[260];
103
+ };
104
+
105
+ /* #if _INTEGRAL_MAX_BITS >= 64 */
106
+
107
+ struct _wfinddata32i64_t {
108
+ unsigned attrib;
109
+ __time32_t time_create;
110
+ __time32_t time_access;
111
+ __time32_t time_write;
112
+ __int64 size;
113
+ wchar_t name[260];
114
+ };
115
+
116
+ struct _wfinddata64i32_t {
117
+ unsigned attrib;
118
+ __time64_t time_create;
119
+ __time64_t time_access;
120
+ __time64_t time_write;
121
+ _fsize_t size;
122
+ wchar_t name[260];
123
+ };
124
+
125
+ struct _wfinddata64_t {
126
+ unsigned attrib;
127
+ __time64_t time_create;
128
+ __time64_t time_access;
129
+ __time64_t time_write;
130
+ __int64 size;
131
+ wchar_t name[260];
132
+ };
133
+ /* #endif */
134
+
135
+ #ifdef _USE_32BIT_TIME_T
136
+ #define _wfinddata_t _wfinddata32_t
137
+ #define _wfinddatai64_t _wfinddata32i64_t
138
+
139
+ #define _wfindfirst _wfindfirst32
140
+ #define _wfindnext _wfindnext32
141
+ #define _wfindfirsti64 _wfindfirst32i64
142
+ #define _wfindnexti64 _wfindnext32i64
143
+ #else
144
+ #define _wfinddata_t _wfinddata64i32_t
145
+ #define _wfinddatai64_t _wfinddata64_t
146
+
147
+ #define _wfindfirst _wfindfirst64i32
148
+ #define _wfindnext _wfindnext64i32
149
+ #define _wfindfirsti64 _wfindfirst64
150
+ #define _wfindnexti64 _wfindnext64
151
+ #endif
152
+
153
+ #define _WFINDDATA_T_DEFINED
154
+ #endif
155
+
156
+ #define _A_NORMAL 0x00
157
+ #define _A_RDONLY 0x01
158
+ #define _A_HIDDEN 0x02
159
+ #define _A_SYSTEM 0x04
160
+ #define _A_SUBDIR 0x10
161
+ #define _A_ARCH 0x20
162
+
163
+ #ifndef _SIZE_T_DEFINED
164
+ #define _SIZE_T_DEFINED
165
+ #undef size_t
166
+ #ifdef _WIN64
167
+ #if defined(__GNUC__) && defined(__STRICT_ANSI__)
168
+ typedef unsigned int size_t __attribute__ ((mode (DI)));
169
+ #else
170
+ typedef unsigned __int64 size_t;
171
+ #endif
172
+ #else
173
+ typedef unsigned int size_t;
174
+ #endif
175
+ #endif
176
+
177
+ #ifndef _SSIZE_T_DEFINED
178
+ #define _SSIZE_T_DEFINED
179
+ #undef ssize_t
180
+ #ifdef _WIN64
181
+ #if defined(__GNUC__) && defined(__STRICT_ANSI__)
182
+ typedef int ssize_t __attribute__ ((mode (DI)));
183
+ #else
184
+ typedef __int64 ssize_t;
185
+ #endif
186
+ #else
187
+ typedef int ssize_t;
188
+ #endif
189
+ #endif
190
+
191
+ #ifndef _OFF_T_DEFINED
192
+ #define _OFF_T_DEFINED
193
+ #ifndef _OFF_T_
194
+ #define _OFF_T_
195
+ typedef long _off_t;
196
+ #if !defined(NO_OLDNAMES) || defined(_POSIX)
197
+ typedef long off_t;
198
+ #endif
199
+ #endif
200
+ #endif
201
+
202
+ #ifndef _OFF64_T_DEFINED
203
+ #define _OFF64_T_DEFINED
204
+ #if defined(__GNUC__) && defined(__STRICT_ANSI__)
205
+ typedef int _off64_t __attribute__ ((mode (DI)));
206
+ #if !defined(NO_OLDNAMES) || defined(_POSIX)
207
+ typedef int off64_t __attribute__ ((mode (DI)));
208
+ #endif
209
+ #else
210
+ typedef long long _off64_t;
211
+ #if !defined(NO_OLDNAMES) || defined(_POSIX)
212
+ typedef long long off64_t;
213
+ #endif
214
+ #endif
215
+ #endif
216
+
217
+ /* Some defines for _access nAccessMode (MS doesn't define them, but
218
+ * it doesn't seem to hurt to add them). */
219
+ #define F_OK 0 /* Check for file existence */
220
+ #define X_OK 1 /* Check for execute permission. */
221
+ #define W_OK 2 /* Check for write permission */
222
+ #define R_OK 4 /* Check for read permission */
223
+
224
+ _CRTIMP int __cdecl _access(const char *_Filename,int _AccessMode);
225
+ _CRTIMP int __cdecl _chmod(const char *_Filename,int _Mode);
226
+ _CRTIMP int __cdecl _chsize(int _FileHandle,long _Size);
227
+ _CRTIMP int __cdecl _close(int _FileHandle);
228
+ _CRTIMP int __cdecl _commit(int _FileHandle);
229
+ _CRTIMP int __cdecl _creat(const char *_Filename,int _PermissionMode);
230
+ _CRTIMP int __cdecl _dup(int _FileHandle);
231
+ _CRTIMP int __cdecl _dup2(int _FileHandleSrc,int _FileHandleDst);
232
+ _CRTIMP int __cdecl _eof(int _FileHandle);
233
+ _CRTIMP long __cdecl _filelength(int _FileHandle);
234
+ _CRTIMP intptr_t __cdecl _findfirst32(const char *_Filename,struct _finddata32_t *_FindData);
235
+ _CRTIMP int __cdecl _findnext32(intptr_t _FindHandle,struct _finddata32_t *_FindData);
236
+ _CRTIMP int __cdecl _findclose(intptr_t _FindHandle);
237
+ _CRTIMP int __cdecl _isatty(int _FileHandle);
238
+ _CRTIMP int __cdecl _locking(int _FileHandle,int _LockMode,long _NumOfBytes);
239
+ _CRTIMP long __cdecl _lseek(int _FileHandle,long _Offset,int _Origin);
240
+ _off64_t lseek64(int fd,_off64_t offset, int whence);
241
+ _CRTIMP char *__cdecl _mktemp(char *_TemplateName);
242
+ _CRTIMP int __cdecl _pipe(int *_PtHandles,unsigned int _PipeSize,int _TextMode);
243
+ _CRTIMP int __cdecl _read(int _FileHandle,void *_DstBuf,unsigned int _MaxCharCount);
244
+
245
+ #ifndef _CRT_DIRECTORY_DEFINED
246
+ #define _CRT_DIRECTORY_DEFINED
247
+ int __cdecl remove(const char *_Filename);
248
+ int __cdecl rename(const char *_OldFilename,const char *_NewFilename);
249
+ _CRTIMP int __cdecl _unlink(const char *_Filename);
250
+ #ifndef NO_OLDNAMES
251
+ int __cdecl unlink(const char *_Filename);
252
+ #endif
253
+ #endif
254
+
255
+ _CRTIMP int __cdecl _setmode(int _FileHandle,int _Mode);
256
+ _CRTIMP long __cdecl _tell(int _FileHandle);
257
+ _CRTIMP int __cdecl _umask(int _Mode);
258
+ _CRTIMP int __cdecl _write(int _FileHandle,const void *_Buf,unsigned int _MaxCharCount);
259
+
260
+ #if _INTEGRAL_MAX_BITS >= 64
261
+ _CRTIMP __int64 __cdecl _filelengthi64(int _FileHandle);
262
+ _CRTIMP intptr_t __cdecl _findfirst32i64(const char *_Filename,struct _finddata32i64_t *_FindData);
263
+ _CRTIMP intptr_t __cdecl _findfirst64(const char *_Filename,struct __finddata64_t *_FindData);
264
+ #ifdef __cplusplus
265
+ #include <string.h>
266
+ #endif
267
+ intptr_t __cdecl _findfirst64i32(const char *_Filename,struct _finddata64i32_t *_FindData);
268
+ __CRT_INLINE intptr_t __cdecl _findfirst64i32(const char *_Filename,struct _finddata64i32_t *_FindData)
269
+ {
270
+ struct __finddata64_t fd;
271
+ intptr_t ret = _findfirst64(_Filename,&fd);
272
+ _FindData->attrib=fd.attrib;
273
+ _FindData->time_create=fd.time_create;
274
+ _FindData->time_access=fd.time_access;
275
+ _FindData->time_write=fd.time_write;
276
+ _FindData->size=(_fsize_t) fd.size;
277
+ strncpy(_FindData->name,fd.name,260);
278
+ return ret;
279
+ }
280
+ _CRTIMP int __cdecl _findnext32i64(intptr_t _FindHandle,struct _finddata32i64_t *_FindData);
281
+ _CRTIMP int __cdecl _findnext64(intptr_t _FindHandle,struct __finddata64_t *_FindData);
282
+ int __cdecl _findnext64i32(intptr_t _FindHandle,struct _finddata64i32_t *_FindData);
283
+ __CRT_INLINE int __cdecl _findnext64i32(intptr_t _FindHandle,struct _finddata64i32_t *_FindData)
284
+ {
285
+ struct __finddata64_t fd;
286
+ int ret = _findnext64(_FindHandle,&fd);
287
+ _FindData->attrib=fd.attrib;
288
+ _FindData->time_create=fd.time_create;
289
+ _FindData->time_access=fd.time_access;
290
+ _FindData->time_write=fd.time_write;
291
+ _FindData->size=(_fsize_t) fd.size;
292
+ strncpy(_FindData->name,fd.name,260);
293
+ return ret;
294
+ }
295
+ __int64 __cdecl _lseeki64(int _FileHandle,__int64 _Offset,int _Origin);
296
+ __int64 __cdecl _telli64(int _FileHandle);
297
+ #endif
298
+ #ifndef NO_OLDNAMES
299
+
300
+ #ifndef _UWIN
301
+ int __cdecl chdir (const char *);
302
+ char *__cdecl getcwd (char *, int);
303
+ int __cdecl mkdir (const char *);
304
+ char *__cdecl mktemp(char *);
305
+ int __cdecl rmdir (const char*);
306
+ int __cdecl chmod (const char *, int);
307
+ #endif /* _UWIN */
308
+
309
+ #endif /* Not NO_OLDNAMES */
310
+
311
+ _CRTIMP errno_t __cdecl _sopen_s(int *_FileHandle,const char *_Filename,int _OpenFlag,int _ShareFlag,int _PermissionMode);
312
+
313
+ #ifndef __cplusplus
314
+ _CRTIMP int __cdecl _open(const char *_Filename,int _OpenFlag,...);
315
+ _CRTIMP int __cdecl _sopen(const char *_Filename,int _OpenFlag,int _ShareFlag,...);
316
+ #else
317
+ extern "C++" _CRTIMP int __cdecl _open(const char *_Filename,int _Openflag,int _PermissionMode = 0);
318
+ extern "C++" _CRTIMP int __cdecl _sopen(const char *_Filename,int _Openflag,int _ShareFlag,int _PermissionMode = 0);
319
+ #endif
320
+
321
+ #ifndef _WIO_DEFINED
322
+ #define _WIO_DEFINED
323
+ _CRTIMP int __cdecl _waccess(const wchar_t *_Filename,int _AccessMode);
324
+ _CRTIMP int __cdecl _wchmod(const wchar_t *_Filename,int _Mode);
325
+ _CRTIMP int __cdecl _wcreat(const wchar_t *_Filename,int _PermissionMode);
326
+ _CRTIMP intptr_t __cdecl _wfindfirst32(const wchar_t *_Filename,struct _wfinddata32_t *_FindData);
327
+ _CRTIMP int __cdecl _wfindnext32(intptr_t _FindHandle,struct _wfinddata32_t *_FindData);
328
+ _CRTIMP int __cdecl _wunlink(const wchar_t *_Filename);
329
+ _CRTIMP int __cdecl _wrename(const wchar_t *_NewFilename,const wchar_t *_OldFilename);
330
+ _CRTIMP wchar_t *__cdecl _wmktemp(wchar_t *_TemplateName);
331
+
332
+ #if _INTEGRAL_MAX_BITS >= 64
333
+ _CRTIMP intptr_t __cdecl _wfindfirst32i64(const wchar_t *_Filename,struct _wfinddata32i64_t *_FindData);
334
+ intptr_t __cdecl _wfindfirst64i32(const wchar_t *_Filename,struct _wfinddata64i32_t *_FindData);
335
+ _CRTIMP intptr_t __cdecl _wfindfirst64(const wchar_t *_Filename,struct _wfinddata64_t *_FindData);
336
+ _CRTIMP int __cdecl _wfindnext32i64(intptr_t _FindHandle,struct _wfinddata32i64_t *_FindData);
337
+ int __cdecl _wfindnext64i32(intptr_t _FindHandle,struct _wfinddata64i32_t *_FindData);
338
+ _CRTIMP int __cdecl _wfindnext64(intptr_t _FindHandle,struct _wfinddata64_t *_FindData);
339
+ #endif
340
+
341
+ _CRTIMP errno_t __cdecl _wsopen_s(int *_FileHandle,const wchar_t *_Filename,int _OpenFlag,int _ShareFlag,int _PermissionFlag);
342
+
343
+ #if !defined(__cplusplus) || !(defined(_X86_) && !defined(__x86_64))
344
+ _CRTIMP int __cdecl _wopen(const wchar_t *_Filename,int _OpenFlag,...);
345
+ _CRTIMP int __cdecl _wsopen(const wchar_t *_Filename,int _OpenFlag,int _ShareFlag,...);
346
+ #else
347
+ extern "C++" _CRTIMP int __cdecl _wopen(const wchar_t *_Filename,int _OpenFlag,int _PermissionMode = 0);
348
+ extern "C++" _CRTIMP int __cdecl _wsopen(const wchar_t *_Filename,int _OpenFlag,int _ShareFlag,int _PermissionMode = 0);
349
+ #endif
350
+
351
+ #endif
352
+
353
+ int __cdecl __lock_fhandle(int _Filehandle);
354
+ void __cdecl _unlock_fhandle(int _Filehandle);
355
+ _CRTIMP intptr_t __cdecl _get_osfhandle(int _FileHandle);
356
+ _CRTIMP int __cdecl _open_osfhandle(intptr_t _OSFileHandle,int _Flags);
357
+
358
+ #ifndef NO_OLDNAMES
359
+ int __cdecl access(const char *_Filename,int _AccessMode);
360
+ int __cdecl chmod(const char *_Filename,int _AccessMode);
361
+ int __cdecl chsize(int _FileHandle,long _Size);
362
+ int __cdecl close(int _FileHandle);
363
+ int __cdecl creat(const char *_Filename,int _PermissionMode);
364
+ int __cdecl dup(int _FileHandle);
365
+ int __cdecl dup2(int _FileHandleSrc,int _FileHandleDst);
366
+ int __cdecl eof(int _FileHandle);
367
+ long __cdecl filelength(int _FileHandle);
368
+ int __cdecl isatty(int _FileHandle);
369
+ int __cdecl locking(int _FileHandle,int _LockMode,long _NumOfBytes);
370
+ long __cdecl lseek(int _FileHandle,long _Offset,int _Origin);
371
+ char *__cdecl mktemp(char *_TemplateName);
372
+ int __cdecl open(const char *_Filename,int _OpenFlag,...);
373
+ int __cdecl read(int _FileHandle,void *_DstBuf,unsigned int _MaxCharCount);
374
+ int __cdecl setmode(int _FileHandle,int _Mode);
375
+ int __cdecl sopen(const char *_Filename,int _OpenFlag,int _ShareFlag,...);
376
+ long __cdecl tell(int _FileHandle);
377
+ int __cdecl umask(int _Mode);
378
+ int __cdecl write(int _Filehandle,const void *_Buf,unsigned int _MaxCharCount);
379
+ #endif
380
+
381
+ #ifdef __cplusplus
382
+ }
383
+ #endif
384
+ #endif
385
+
386
+ #ifdef __cplusplus
387
+ extern "C" {
388
+ #endif
389
+
390
+ /* Misc stuff */
391
+ char *getlogin(void);
392
+ #ifdef __USE_MINGW_ALARM
393
+ unsigned int alarm(unsigned int seconds);
394
+ #endif
395
+
396
+ #ifdef __USE_MINGW_ACCESS
397
+ /* Old versions of MSVCRT access() just ignored X_OK, while the version
398
+ shipped with Vista, returns an error code. This will restore the
399
+ old behaviour */
400
+ static inline int __mingw_access (const char *__fname, int __mode) {
401
+ return _access (__fname, __mode & ~X_OK);
402
+ }
403
+
404
+ #define access(__f,__m) __mingw_access (__f, __m)
405
+ #endif
406
+
407
+
408
+ #ifdef __cplusplus
409
+ }
410
+ #endif
411
+
412
+
413
+ #pragma pack(pop)
414
+
415
+ #include <sec_api/io_s.h>
416
+
417
+ #endif /* End _IO_H_ */
418
+
@@ -0,0 +1,36 @@
1
+ /**
2
+ * This file has no copyright assigned and is placed in the Public Domain.
3
+ * This file is part of the TinyCC package.
4
+ * No warranty is given; refer to the file DISCLAIMER within this package.
5
+ */
6
+
7
+ /*
8
+ * ISO C Standard: 7.9 Alternative spellings <iso646.h>
9
+ */
10
+
11
+ #ifndef _ISO646_H_
12
+ #define _ISO646_H_
13
+
14
+ #define and &&
15
+ #define and_eq &=
16
+ #define bitand &
17
+ #define bitor |
18
+ #define compl ~
19
+ #define not !
20
+ #define not_eq !=
21
+ #define or ||
22
+ #define or_eq |=
23
+ #define xor ^
24
+ #define xor_eq ^=
25
+
26
+ #endif /* _ISO646_H_ */
27
+
28
+
29
+
30
+
31
+
32
+
33
+
34
+
35
+
36
+
@@ -0,0 +1,116 @@
1
+ /**
2
+ * This file has no copyright assigned and is placed in the Public Domain.
3
+ * This file is part of the w64 mingw-runtime package.
4
+ * No warranty is given; refer to the file DISCLAIMER within this package.
5
+ */
6
+ #include <_mingw.h>
7
+
8
+ #ifndef _INC_LIMITS
9
+ #define _INC_LIMITS
10
+
11
+ /*
12
+ * File system limits
13
+ *
14
+ * TODO: NAME_MAX and OPEN_MAX are file system limits or not? Are they the
15
+ * same as FILENAME_MAX and FOPEN_MAX from stdio.h?
16
+ * NOTE: Apparently the actual size of PATH_MAX is 260, but a space is
17
+ * required for the NUL. TODO: Test?
18
+ */
19
+ #define PATH_MAX (259)
20
+
21
+ #define CHAR_BIT 8
22
+ #define SCHAR_MIN (-128)
23
+ #define SCHAR_MAX 127
24
+ #define UCHAR_MAX 0xff
25
+
26
+ #ifndef __CHAR_UNSIGNED__
27
+ #define CHAR_MIN SCHAR_MIN
28
+ #define CHAR_MAX SCHAR_MAX
29
+ #else
30
+ #define CHAR_MIN 0
31
+ #define CHAR_MAX UCHAR_MAX
32
+ #endif
33
+
34
+ #define MB_LEN_MAX 5
35
+ #define SHRT_MIN (-32768)
36
+ #define SHRT_MAX 32767
37
+ #define USHRT_MAX 0xffff
38
+ #define INT_MIN (-2147483647 - 1)
39
+ #define INT_MAX 2147483647
40
+ #define UINT_MAX 0xffffffff
41
+ #define LONG_MIN (-2147483647L - 1)
42
+ #define LONG_MAX 2147483647L
43
+ #define ULONG_MAX 0xffffffffUL
44
+ #define LLONG_MAX 9223372036854775807ll
45
+ #define LLONG_MIN (-9223372036854775807ll - 1)
46
+ #define ULLONG_MAX 0xffffffffffffffffull
47
+
48
+ #if _INTEGRAL_MAX_BITS >= 8
49
+ #define _I8_MIN (-127 - 1)
50
+ #define _I8_MAX 127i8
51
+ #define _UI8_MAX 0xffu
52
+ #endif
53
+
54
+ #if _INTEGRAL_MAX_BITS >= 16
55
+ #define _I16_MIN (-32767 - 1)
56
+ #define _I16_MAX 32767i16
57
+ #define _UI16_MAX 0xffffu
58
+ #endif
59
+
60
+ #if _INTEGRAL_MAX_BITS >= 32
61
+ #define _I32_MIN (-2147483647 - 1)
62
+ #define _I32_MAX 2147483647
63
+ #define _UI32_MAX 0xffffffffu
64
+ #endif
65
+
66
+ #if defined(__GNUC__)
67
+ #undef LONG_LONG_MAX
68
+ #define LONG_LONG_MAX 9223372036854775807ll
69
+ #undef LONG_LONG_MIN
70
+ #define LONG_LONG_MIN (-LONG_LONG_MAX-1)
71
+ #undef ULONG_LONG_MAX
72
+ #define ULONG_LONG_MAX (2ull * LONG_LONG_MAX + 1ull)
73
+ #endif
74
+
75
+ #if _INTEGRAL_MAX_BITS >= 64
76
+ #define _I64_MIN (-9223372036854775807ll - 1)
77
+ #define _I64_MAX 9223372036854775807ll
78
+ #define _UI64_MAX 0xffffffffffffffffull
79
+ #endif
80
+
81
+ #ifndef SIZE_MAX
82
+ #ifdef _WIN64
83
+ #define SIZE_MAX _UI64_MAX
84
+ #else
85
+ #define SIZE_MAX UINT_MAX
86
+ #endif
87
+ #endif
88
+
89
+ #ifdef _POSIX_
90
+ #define _POSIX_ARG_MAX 4096
91
+ #define _POSIX_CHILD_MAX 6
92
+ #define _POSIX_LINK_MAX 8
93
+ #define _POSIX_MAX_CANON 255
94
+ #define _POSIX_MAX_INPUT 255
95
+ #define _POSIX_NAME_MAX 14
96
+ #define _POSIX_NGROUPS_MAX 0
97
+ #define _POSIX_OPEN_MAX 16
98
+ #define _POSIX_PATH_MAX 255
99
+ #define _POSIX_PIPE_BUF 512
100
+ #define _POSIX_SSIZE_MAX 32767
101
+ #define _POSIX_STREAM_MAX 8
102
+ #define _POSIX_TZNAME_MAX 3
103
+ #define ARG_MAX 14500
104
+ #define LINK_MAX 1024
105
+ #define MAX_CANON _POSIX_MAX_CANON
106
+ #define MAX_INPUT _POSIX_MAX_INPUT
107
+ #define NAME_MAX 255
108
+ #define NGROUPS_MAX 16
109
+ #define OPEN_MAX 32
110
+ #define PATH_MAX 512
111
+ #define PIPE_BUF _POSIX_PIPE_BUF
112
+ #define SSIZE_MAX _POSIX_SSIZE_MAX
113
+ #define STREAM_MAX 20
114
+ #define TZNAME_MAX 10
115
+ #endif
116
+ #endif
@@ -0,0 +1,91 @@
1
+ /**
2
+ * This file has no copyright assigned and is placed in the Public Domain.
3
+ * This file is part of the w64 mingw-runtime package.
4
+ * No warranty is given; refer to the file DISCLAIMER within this package.
5
+ */
6
+ #ifndef _INC_LOCALE
7
+ #define _INC_LOCALE
8
+
9
+ #include <_mingw.h>
10
+
11
+ #pragma pack(push,_CRT_PACKING)
12
+
13
+ #ifdef __cplusplus
14
+ extern "C" {
15
+ #endif
16
+
17
+ #ifndef NULL
18
+ #ifdef __cplusplus
19
+ #define NULL 0
20
+ #else
21
+ #define NULL ((void *)0)
22
+ #endif
23
+ #endif
24
+
25
+ #define LC_ALL 0
26
+ #define LC_COLLATE 1
27
+ #define LC_CTYPE 2
28
+ #define LC_MONETARY 3
29
+ #define LC_NUMERIC 4
30
+ #define LC_TIME 5
31
+
32
+ #define LC_MIN LC_ALL
33
+ #define LC_MAX LC_TIME
34
+
35
+ #ifndef _LCONV_DEFINED
36
+ #define _LCONV_DEFINED
37
+ struct lconv {
38
+ char *decimal_point;
39
+ char *thousands_sep;
40
+ char *grouping;
41
+ char *int_curr_symbol;
42
+ char *currency_symbol;
43
+ char *mon_decimal_point;
44
+ char *mon_thousands_sep;
45
+ char *mon_grouping;
46
+ char *positive_sign;
47
+ char *negative_sign;
48
+ char int_frac_digits;
49
+ char frac_digits;
50
+ char p_cs_precedes;
51
+ char p_sep_by_space;
52
+ char n_cs_precedes;
53
+ char n_sep_by_space;
54
+ char p_sign_posn;
55
+ char n_sign_posn;
56
+ };
57
+ #endif
58
+
59
+ #ifndef _CONFIG_LOCALE_SWT
60
+ #define _CONFIG_LOCALE_SWT
61
+
62
+ #define _ENABLE_PER_THREAD_LOCALE 0x1
63
+ #define _DISABLE_PER_THREAD_LOCALE 0x2
64
+ #define _ENABLE_PER_THREAD_LOCALE_GLOBAL 0x10
65
+ #define _DISABLE_PER_THREAD_LOCALE_GLOBAL 0x20
66
+ #define _ENABLE_PER_THREAD_LOCALE_NEW 0x100
67
+ #define _DISABLE_PER_THREAD_LOCALE_NEW 0x200
68
+
69
+ #endif
70
+
71
+ int __cdecl _configthreadlocale(int _Flag);
72
+ char *__cdecl setlocale(int _Category,const char *_Locale);
73
+ _CRTIMP struct lconv *__cdecl localeconv(void);
74
+ _locale_t __cdecl _get_current_locale(void);
75
+ _locale_t __cdecl _create_locale(int _Category,const char *_Locale);
76
+ void __cdecl _free_locale(_locale_t _Locale);
77
+ _locale_t __cdecl __get_current_locale(void);
78
+ _locale_t __cdecl __create_locale(int _Category,const char *_Locale);
79
+ void __cdecl __free_locale(_locale_t _Locale);
80
+
81
+ #ifndef _WLOCALE_DEFINED
82
+ #define _WLOCALE_DEFINED
83
+ _CRTIMP wchar_t *__cdecl _wsetlocale(int _Category,const wchar_t *_Locale);
84
+ #endif
85
+
86
+ #ifdef __cplusplus
87
+ }
88
+ #endif
89
+
90
+ #pragma pack(pop)
91
+ #endif