We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 10943c8 commit a7ef552Copy full SHA for a7ef552
1 file changed
cuda_bindings/cuda/bindings/utils/_nvvm_utils.py
@@ -1,6 +1,7 @@
1
# SPDX-FileCopyrightText: Copyright (c) 2026-2027 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
2
# SPDX-License-Identifier: LicenseRef-NVIDIA-SOFTWARE-LICENSE
3
4
+import contextlib
5
from typing import Sequence
6
7
_PRECHECK_NVVM_IR = """target triple = "nvptx64-unknown-cuda"
@@ -87,8 +88,6 @@ def check_nvvm_options(options: Sequence[bytes]) -> bool:
87
88
return False
89
finally:
90
if program is not None:
- try:
91
+ with contextlib.suppress(Exception):
92
nvvm.destroy_program(program)
- except Exception:
93
- pass
94
return True
0 commit comments