Commit 86adb00
[FEA]: Add per-library path override env var to cuda.pathfinder
Adds CUDA_PATHFINDER_<LIBNAME_UPPER>_PATH_OVERRIDE as a developer
escape hatch for pointing cuda.pathfinder at a custom build of a
specific library (e.g. a development branch of nvshmem) without
having to remove the wheel or copy .so files into site-packages.
The value can be either an absolute file path (used as-is) or a
directory (searched with the same platform logic as conda /
CUDA_PATH). The override has the highest priority and applies
uniformly to CTK, third-party, and driver libraries.
If the env var is set but the library cannot be resolved from it,
the load fails immediately rather than silently falling through to
other search steps. This keeps the override behavior explicit and
easy to debug.
Closes #1054.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 8a83a4f commit 86adb00
3 files changed
Lines changed: 148 additions & 11 deletions
File tree
- cuda_pathfinder
- cuda/pathfinder/_dynamic_libs
- tests
Lines changed: 31 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
| 27 | + | |
27 | 28 | | |
28 | 29 | | |
29 | 30 | | |
| |||
60 | 61 | | |
61 | 62 | | |
62 | 63 | | |
63 | | - | |
| 64 | + | |
| 65 | + | |
64 | 66 | | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
65 | 71 | | |
66 | 72 | | |
67 | 73 | | |
| |||
221 | 227 | | |
222 | 228 | | |
223 | 229 | | |
224 | | - | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
225 | 245 | | |
226 | 246 | | |
227 | 247 | | |
228 | 248 | | |
229 | | - | |
| 249 | + | |
230 | 250 | | |
231 | 251 | | |
232 | 252 | | |
233 | 253 | | |
234 | | - | |
| 254 | + | |
235 | 255 | | |
236 | 256 | | |
237 | 257 | | |
238 | 258 | | |
239 | 259 | | |
240 | | - | |
| 260 | + | |
241 | 261 | | |
242 | 262 | | |
243 | 263 | | |
| |||
253 | 273 | | |
254 | 274 | | |
255 | 275 | | |
256 | | - | |
| 276 | + | |
257 | 277 | | |
258 | 278 | | |
259 | 279 | | |
260 | 280 | | |
261 | 281 | | |
262 | 282 | | |
263 | | - | |
| 283 | + | |
264 | 284 | | |
265 | 285 | | |
266 | 286 | | |
267 | 287 | | |
268 | 288 | | |
269 | 289 | | |
270 | | - | |
| 290 | + | |
271 | 291 | | |
272 | 292 | | |
273 | 293 | | |
274 | 294 | | |
275 | 295 | | |
276 | 296 | | |
277 | 297 | | |
278 | | - | |
279 | | - | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
280 | 301 | | |
281 | 302 | | |
282 | 303 | | |
| |||
Lines changed: 51 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
158 | 158 | | |
159 | 159 | | |
160 | 160 | | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
161 | 209 | | |
162 | 210 | | |
163 | 211 | | |
| |||
208 | 256 | | |
209 | 257 | | |
210 | 258 | | |
211 | | - | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
212 | 262 | | |
213 | 263 | | |
214 | 264 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
| 25 | + | |
24 | 26 | | |
25 | 27 | | |
26 | 28 | | |
| |||
440 | 442 | | |
441 | 443 | | |
442 | 444 | | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
0 commit comments