Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

System shared libraries should be preferred when newer than the bundled ones in the wheel #1340

Open
danielzgtg opened this issue Dec 22, 2023 · 0 comments

Comments

@danielzgtg
Copy link

🐛 Describe the bug

Sample code to reproduce the problem

See ROCm/rocBLAS#1386 . This is mainly encountered after installing updating from ROCm 5.7.1 to ROCm 6.0, and compiling bitsandbytes-foundation/bitsandbytes#756 with it, while pytorch is still stuck on https://download.pytorch.org/whl/rocm5.6 .

rocBLAS error: Could not load /opt/rocm-6.0.0/lib/rocblas/library/TensileLibrary_lazy_gfx1030.dat

rocBLAS error: Could not initialize Tensile library

Thread 1 "python3" received signal SIGABRT, Aborted.

gdb_backtrace.txt

pytorch-rocm should not bundle its ROCm libraries in its wheel. It should use the system libraries in /opt, so that they can be updated, and that there are no shared library version conflicts. If this is not possible, it should at least only load its own libraries if they are newer, or warn about incompatible shared libraries being mixed in the same process.

Versions

Working version
Collecting environment information...
PyTorch version: 2.3.0a0+gitb5c866d
Is debug build: False
CUDA used to build PyTorch: N/A
ROCM used to build PyTorch: 6.0.32830-d62f6a171

OS: Ubuntu 23.10 (x86_64)
GCC version: (Ubuntu 13.2.0-4ubuntu3) 13.2.0
Clang version: 16.0.6 (15)
CMake version: version 3.27.4
Libc version: glibc-2.38

Python version: 3.11.6 (main, Oct  8 2023, 05:06:43) [GCC 13.2.0] (64-bit runtime)
Python platform: Linux-6.6.0-rc7+-x86_64-with-glibc2.38
Is CUDA available: True
CUDA runtime version: Could not collect
CUDA_MODULE_LOADING set to: LAZY
GPU models and configuration: AMD Radeon RX 6650 XT (gfx1030)
Nvidia driver version: Could not collect
cuDNN version: Could not collect
HIP runtime version: 6.0.32830
MIOpen runtime version: 3.0.0
Is XNNPACK available: True

CPU:
Architecture:                       x86_64
CPU op-mode(s):                     32-bit, 64-bit
Address sizes:                      48 bits physical, 48 bits virtual
Byte Order:                         Little Endian
CPU(s):                             24
On-line CPU(s) list:                0-23
Vendor ID:                          AuthenticAMD
Model name:                         AMD Ryzen 9 5900X 12-Core Processor
CPU family:                         25
Model:                              33
Thread(s) per core:                 2
Core(s) per socket:                 12
Socket(s):                          1
Stepping:                           2
Frequency boost:                    enabled
CPU(s) scaling MHz:                 58%
CPU max MHz:                        4950.1948
CPU min MHz:                        2200.0000
BogoMIPS:                           7399.77
Flags:                              fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm constant_tsc rep_good nopl nonstop_tsc cpuid extd_apicid aperfmperf rapl pni pclmulqdq monitor ssse3 fma cx16 sse4_1 sse4_2 x2apic movbe popcnt aes xsave avx f16c rdrand lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt tce topoext perfctr_core perfctr_nb bpext perfctr_llc mwaitx cpb cat_l3 cdp_l3 hw_pstate ssbd mba ibrs ibpb stibp vmmcall fsgsbase bmi1 avx2 smep bmi2 erms invpcid cqm rdt_a rdseed adx smap clflushopt clwb sha_ni xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local clzero irperf xsaveerptr rdpru wbnoinvd arat npt lbrv svm_lock nrip_save tsc_scale vmcb_clean flushbyasid decodeassists pausefilter pfthreshold avic v_vmsave_vmload vgif v_spec_ctrl umip pku ospke vaes vpclmulqdq rdpid overflow_recov succor smca fsrm debug_swap
Virtualization:                     AMD-V
L1d cache:                          384 KiB (12 instances)
L1i cache:                          384 KiB (12 instances)
L2 cache:                           6 MiB (12 instances)
L3 cache:                           64 MiB (2 instances)
NUMA node(s):                       1
NUMA node0 CPU(s):                  0-23
Vulnerability Gather data sampling: Not affected
Vulnerability Itlb multihit:        Not affected
Vulnerability L1tf:                 Not affected
Vulnerability Mds:                  Not affected
Vulnerability Meltdown:             Not affected
Vulnerability Mmio stale data:      Not affected
Vulnerability Retbleed:             Not affected
Vulnerability Spec rstack overflow: Mitigation; safe RET
Vulnerability Spec store bypass:    Mitigation; Speculative Store Bypass disabled via prctl
Vulnerability Spectre v1:           Mitigation; usercopy/swapgs barriers and __user pointer sanitization
Vulnerability Spectre v2:           Mitigation; Retpolines, IBPB conditional, IBRS_FW, STIBP always-on, RSB filling, PBRSB-eIBRS Not affected
Vulnerability Srbds:                Not affected
Vulnerability Tsx async abort:      Not affected

Versions of relevant libraries:
[pip3] mypy-extensions==1.0.0
[pip3] numpy==1.23.5
[pip3] open-clip-torch==2.20.0
[pip3] pytorch-lightning==1.9.4
[pip3] pytorch-triton-rocm==2.1.0
[pip3] torch==2.3.0a0+gitb5c866d
[pip3] torchdiffeq==0.2.3
[pip3] torchmetrics==1.2.1
[pip3] torchsde==0.2.6
[pip3] triton==2.1.0
[conda] Could not collect
Broken version
Collecting environment information...
Traceback (most recent call last):
  File "/home/home/PycharmProjects/stable-diffusion-webui/collect_env.py", line 617, in <module>
    main()
  File "/home/home/PycharmProjects/stable-diffusion-webui/collect_env.py", line 600, in main
    output = get_pretty_env_info()
             ^^^^^^^^^^^^^^^^^^^^^
  File "/home/home/PycharmProjects/stable-diffusion-webui/collect_env.py", line 595, in get_pretty_env_info
    return pretty_str(get_env_info())
                      ^^^^^^^^^^^^^^
  File "/home/home/PycharmProjects/stable-diffusion-webui/collect_env.py", line 467, in get_env_info
    nvidia_gpu_models=get_gpu_info(run_lambda),
                      ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/home/PycharmProjects/stable-diffusion-webui/collect_env.py", line 152, in get_gpu_info
    (" ({})".format(torch.cuda.get_device_properties(0).gcnArchName) if torch.version.hip is not None else "")
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'torch._C._CudaDeviceProperties' object has no attribute 'gcnArchName'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants