Skip to content

Commit 509c8dc

Browse files
committed
Exclude Windows-unavailable bitcode libs from SUPPORTED_BITCODE_LIBS
nvshmem wheels are not published for Windows, so the nvshmem_device entry must be filtered out on that platform. This adds an `available_on_windows` key to _BitcodeLibInfo and uses it to build SUPPORTED_BITCODE_LIBS, which controls test parametrization. Made-with: Cursor
1 parent a6f24d7 commit 509c8dc

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

cuda_pathfinder/cuda/pathfinder/_static_libs/find_bitcode_lib.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ class _BitcodeLibInfo(TypedDict):
2929
filename: str
3030
rel_path: str
3131
site_packages_dirs: tuple[str, ...]
32+
available_on_windows: bool
3233

3334

3435
_SUPPORTED_BITCODE_LIBS_INFO: dict[str, _BitcodeLibInfo] = {
@@ -39,16 +40,22 @@ class _BitcodeLibInfo(TypedDict):
3940
"nvidia/cu13/nvvm/libdevice",
4041
"nvidia/cuda_nvcc/nvvm/libdevice",
4142
),
43+
"available_on_windows": True,
4244
},
4345
"nvshmem_device": {
4446
"filename": "libnvshmem_device.bc",
4547
"rel_path": "lib",
4648
"site_packages_dirs": ("nvidia/nvshmem/lib",),
49+
"available_on_windows": False,
4750
},
4851
}
4952

5053
# Public API: just the supported library names
51-
SUPPORTED_BITCODE_LIBS: tuple[str, ...] = tuple(sorted(_SUPPORTED_BITCODE_LIBS_INFO.keys()))
54+
SUPPORTED_BITCODE_LIBS: tuple[str, ...] = tuple(
55+
sorted(
56+
name for name, info in _SUPPORTED_BITCODE_LIBS_INFO.items() if not IS_WINDOWS or info["available_on_windows"]
57+
)
58+
)
5259

5360

5461
def _no_such_file_in_dir(dir_path: str, filename: str, error_messages: list[str], attachments: list[str]) -> None:

0 commit comments

Comments
 (0)