Fix python -O mode issues

This commit is contained in:
Chenggang Zhao 2025-02-27 10:42:46 +08:00
parent d5b974da2b
commit 6e55da296f

View File

@ -136,7 +136,8 @@ def build(name: str, arg_defs: tuple, code: str) -> Runtime:
*[f'-I{d}' for d in include_dirs]]
if os.getenv('DG_JIT_DEBUG', None) or os.getenv('DG_JIT_PRINT_NVCC_COMMAND', False):
print(f'Compiling JIT runtime {name} with command {command}')
assert subprocess.check_call(command) == 0, f'Failed to compile {src_path}'
return_code = subprocess.check_call(command)
assert return_code == 0, f'Failed to compile {src_path}'
# Interleave FFMA reuse
if enable_sass_opt: