triton-windows 3.3.0a0.post14__cp39-cp39-win_amd64.whl → 3.3.0a0.post16__cp39-cp39-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.

triton/_C/libtriton.pyd CHANGED
Binary file
@@ -403,11 +403,10 @@ class CUDABackend(BaseBackend):
403
403
 
404
404
  def make_cubin(self, src, metadata, opt, capability):
405
405
  ptxas, _ = get_ptxas(self.target.arch)
406
- # On Windows, we need to set delete=False, close the temp file before reading it, and manually remove it
407
406
  with tempfile.NamedTemporaryFile(delete=False, mode='w', suffix='.ptx') as fsrc, \
408
407
  tempfile.NamedTemporaryFile(delete=False, mode='r', suffix='.log') as flog:
409
408
  fsrc.write(src)
410
- fsrc.close()
409
+ fsrc.flush()
411
410
  fbin = fsrc.name + '.o'
412
411
 
413
412
  line_info = ["-lineinfo", "-suppress-debug-info"] if os.environ.get("TRITON_DISABLE_LINE_INFO",
@@ -417,10 +416,8 @@ class CUDABackend(BaseBackend):
417
416
  opt_level = ['--opt-level', '0'] if os.environ.get("DISABLE_PTXAS_OPT", "0") == "1" else []
418
417
  ptxas_cmd = [ptxas, *line_info, *fmad, '-v', *opt_level, f'--gpu-name={arch}', fsrc.name, '-o', fbin]
419
418
  try:
420
- subprocess.run(ptxas_cmd, check=True, close_fds=False, stdout=flog, stderr=flog)
421
- flog.close()
419
+ subprocess.run(ptxas_cmd, check=True, close_fds=True, stdout=flog, stderr=flog)
422
420
  except subprocess.CalledProcessError as e:
423
- flog.close()
424
421
  with open(flog.name) as log_file:
425
422
  log = log_file.read()
426
423
 
@@ -434,13 +431,14 @@ class CUDABackend(BaseBackend):
434
431
  raise PTXASError(f"{error}\n"
435
432
  f"`ptxas` stderr:\n{log}\n"
436
433
  f'Repro command: {" ".join(ptxas_cmd)}\n')
437
- finally:
438
- try_remove(fsrc.name)
439
- try_remove(flog.name)
440
434
 
441
- with open(fbin, 'rb') as f:
442
- cubin = f.read()
443
- try_remove(fbin)
435
+ with open(fbin, 'rb') as f:
436
+ cubin = f.read()
437
+ try_remove(fbin)
438
+
439
+ # It's better to remove the temp files outside the context managers
440
+ try_remove(fsrc.name)
441
+ try_remove(flog.name)
444
442
  return cubin
445
443
 
446
444
  def add_stages(self, stages, options):
@@ -9,6 +9,7 @@
9
9
 
10
10
  #include <stdbool.h>
11
11
  #define PY_SSIZE_T_CLEAN
12
+ #define Py_LIMITED_API 0x03090000
12
13
  #include <Python.h>
13
14
 
14
15
  // Raises a Python exception and returns false if code is not CUDA_SUCCESS.
@@ -206,6 +206,8 @@ def make_launcher(constants, signature):
206
206
  src = f"""
207
207
  #include \"cuda.h\"
208
208
  #include <stdbool.h>
209
+ #define PY_SSIZE_T_CLEAN
210
+ #define Py_LIMITED_API 0x03090000
209
211
  #include <Python.h>
210
212
 
211
213
  #ifndef _WIN32
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.2
1
+ Metadata-Version: 2.4
2
2
  Name: triton-windows
3
- Version: 3.3.0a0.post14
3
+ Version: 3.3.0a0.post16
4
4
  Summary: A language and compiler for custom Deep Learning operations
5
5
  Home-page: https://github.com/woct0rdho/triton-windows
6
6
  Author: Philippe Tillet, Dian Wu
@@ -4,7 +4,7 @@ triton/_utils.py,sha256=5RiCLwW14w0Q3mdZ-9yz-VO5KiSexNj9xeDt4gaNsvE,1014
4
4
  triton/errors.py,sha256=8WfnuRKLG578mgY6cBA3ECruVMf9ULEKFNgRcJ6IhWM,89
5
5
  triton/testing.py,sha256=ivFf1Fq9frmfVahaVUp0bgJxmvVZNACZfj3Sai6zfAs,20048
6
6
  triton/windows_utils.py,sha256=aQMItmuZNXaki8zSB7HMvhy1RsXlmz1GcO-lORm1IIk,10852
7
- triton/_C/libtriton.pyd,sha256=hyIqWiSBaVnnxLUjjZF23t8FCfWOX0hGOYvQcVviTCo,86823424
7
+ triton/_C/libtriton.pyd,sha256=Mo1TfRFiaem1-G90baea4QQ3JpOU_9j-HP5903E0Y0Q,86823424
8
8
  triton/backends/__init__.py,sha256=opAo_vgEMt3tLO_bYFrYGksnIu0qohbmyuu_s3-rNAs,1595
9
9
  triton/backends/compiler.py,sha256=ymaG0kpveAuESbQ9QZ0RyXjr0Aq4el_G5XGYogJ2gNA,3588
10
10
  triton/backends/driver.py,sha256=AN60upJlPgia0JwvZ8vIVgLITNPuI0fdz8zMIIHPpF4,1450
@@ -112,9 +112,9 @@ triton/backends/amd/lib/asanrtl.bc,sha256=1xv2RlU3WvbdsghHlmhwiHewGM2B5dKts5bERM
112
112
  triton/backends/amd/lib/ockl.bc,sha256=wQKCzkKukIHbu0lyjKUYlhndc7S27xto6L54J0Bn-C0,246124
113
113
  triton/backends/amd/lib/ocml.bc,sha256=UPNTXW0gCXUNB-c6orSYwb-mz9_mjUc7zny_vfFza44,205964
114
114
  triton/backends/nvidia/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
115
- triton/backends/nvidia/compiler.py,sha256=R0WKIM_JsMcd3nlwnrlB8pXPjyDj6egaaFxNwi2hneM,18588
116
- triton/backends/nvidia/driver.c,sha256=-O-Q00SFcCHJiHvArIC7yB10Ma1W8jw7ORFKp7spxHE,18846
117
- triton/backends/nvidia/driver.py,sha256=9ZhZTs19M5IU4fAD4JBNhh24MYcP6QLmEMW3SfGgfAQ,20843
115
+ triton/backends/nvidia/compiler.py,sha256=iHbIl-HXSgD3S5eJIXbQhr-Cyk9Gq_g8RXDFZxAGUF4,18444
116
+ triton/backends/nvidia/driver.c,sha256=RWzdn9_RWaaVxXKtdrvxoRg4yR7WSH7ELRyjGDYKwBM,18880
117
+ triton/backends/nvidia/driver.py,sha256=BcEzr0_ONM8H_DKoCbNuO1jRpBM_XHKBgt_Y2bG9aZw,20902
118
118
  triton/backends/nvidia/bin/ptxas.exe,sha256=iCva9hIYg-Q2NybchwaQJFkwDzNiliFOTDdZrHPLb6A,24732160
119
119
  triton/backends/nvidia/include/cuda.h,sha256=Fn44OjeRImxegJ39apYUspseEfTWNGwpqSGUOnHj5WY,1183268
120
120
  triton/backends/nvidia/lib/libdevice.10.bc,sha256=XC-uN8huaMOjhgWpX1EtfRLV89uYYxC-R_VzBKpype4,473728
@@ -247,7 +247,7 @@ triton/tools/link.py,sha256=u7qtfZRLriZkAMEGNvj8YF-k1cthmLL7BwHYqBgT63E,11871
247
247
  triton/tools/mxfp.py,sha256=YQdpBrGkOVNOtnLeRjMCeVFHWkSwUubGeWsItIjO8TU,11737
248
248
  triton/tools/extra/cuda/compile.c,sha256=Me7beHPc6WNTwjg85H84DUMCRu4KJdVK2hNNgvlhBZ4,2126
249
249
  triton/tools/extra/cuda/compile.h,sha256=n9QKIFZTL4RSsiXtAxBP9XGSnxjyaevQQ9bBpwDsvAg,332
250
- triton_windows-3.3.0a0.post14.dist-info/METADATA,sha256=tYF6HEgycHirPm3FRqIWkuxccUaU5kG2duUj8DEUCAM,1629
251
- triton_windows-3.3.0a0.post14.dist-info/WHEEL,sha256=fvNoTPbNdRAfsv1hWsmn2TKqULUpllfaSGBE1Ye0N8Q,99
252
- triton_windows-3.3.0a0.post14.dist-info/top_level.txt,sha256=KhMzHYsArnZ3IkjAQ-xLnx1n_FjvEpJNelg2xPiDl-U,254
253
- triton_windows-3.3.0a0.post14.dist-info/RECORD,,
250
+ triton_windows-3.3.0a0.post16.dist-info/METADATA,sha256=soxppI1GtZ5SPZoHEK6khzoUWAnqHdzSINwOc5AsKLs,1629
251
+ triton_windows-3.3.0a0.post16.dist-info/WHEEL,sha256=DiyQlQBAA8vWmmwFRDPSwjrGdTC0GCx3phqzmWJ5fvE,99
252
+ triton_windows-3.3.0a0.post16.dist-info/top_level.txt,sha256=KhMzHYsArnZ3IkjAQ-xLnx1n_FjvEpJNelg2xPiDl-U,254
253
+ triton_windows-3.3.0a0.post16.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (76.0.0)
2
+ Generator: setuptools (77.0.1)
3
3
  Root-Is-Purelib: false
4
4
  Tag: cp39-cp39-win_amd64
5
5