B300 NVFP4 port: add get_cuda_driver_bindings to utils.common (C3 comm_fusion dep)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-06-21 14:53:05 +00:00
co-authored by Claude Opus 4.8
parent 7225a17c58
commit 2670c6c51b
+9
View File
@@ -3354,6 +3354,15 @@ def check_cuda_result(raw_output):
return results
def get_cuda_driver_bindings():
try:
from cuda.bindings import driver as cuda_driver
except ImportError:
from cuda import cuda as cuda_driver
return cuda_driver
def get_physical_device_id(pytorch_device_id: int) -> int:
"""
Convert PyTorch logical device ID to physical device ID.