question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

About cupy build error in HIP (AMD ROCm) environment

See original GitHub issue

Hello,I tried to build an environment based on ROCm for Cupy but failed I tried HIP build on “cupy v7.0.0 rc1” but it failed in some environments. I have built and tried multiple environments and reproduced a similar error.

Env1 OS Ubuntu 18.04.3 Xeon E5-2603 v4 gcc 7.4.0 GPU RadeonⅦ ROCm version 2.9.6 MiOpen Version: 2.1.0.7487-rocm-rel-2.9-6-a5a4129

Env2 Run on Env1 ROCm Docker based env The same build error was reproduced in the following Dockerfile https://gist.github.com/KeigoTakamura/188295b7a5a07215d90348c769af3dbc

Env3

OS ubuntu 18.04.3 eGPU Base Dynabook U63 CPU Corei5 7300U GPU Vega56 ROCm version 2.9.6

The following build errors were confirmed in the above environment

cupy/cuda/runtime.cpp: In function 'int __pyx_f_4cupy_4cuda_7runtime_deviceGetByPCIBusId(PyObject*, int)':
cupy/cuda/runtime.cpp:3966:83: error: 'cudaDeviceGetByPCIBusId' was not declared in this scope
   __pyx_v_status = cudaDeviceGetByPCIBusId((&__pyx_v_device), __pyx_v_c_pci_bus_id);
                                                                                   ^
cupy/cuda/runtime.cpp: In function 'PyObject* __pyx_f_4cupy_4cuda_7runtime_deviceGetPCIBusId(int, int)':
cupy/cuda/runtime.cpp:4076:80: error: 'cudaDeviceGetPCIBusId' was not declared in this scope
   __pyx_v_status = cudaDeviceGetPCIBusId(__pyx_v_pci_bus_id, 13, __pyx_v_device);
                                                                                ^
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

This error could not be reproduced in some environments of ubuntu16.04 LST, but this error was confirmed in multiple environments and machines

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
KeigoTakamuracommented, Nov 30, 2019

Finished processing dependencies for cupy==7.0.0rc1

Build succeeded Thank you for a good job!!!

1reaction
leofangcommented, Nov 30, 2019

@KeigoTakamura Could you try again the patch from the same PR? I added a stub for libraryPropertyType_t. (Sorry I don’t have an AMD card to test it myself…)

Read more comments on GitHub >

github_iconTop Results From Across the Web

[Experimental] Installation Guide for ROCm environemt - CuPy
pip fails to install CuPy​​ If you are using certain versions of conda, it may fail to build CuPy with error g++: error:...
Read more >
HIP Debugging — ROCm 4.5.0 documentation
The fault will be caught by the runtime but was actually generated by an asynchronous command running on the GPU. · To determine...
Read more >
CuPy on AMD GPU causing an ImportError - Stack Overflow
For CuPy v8.x (the latest stable releases): Up to v8.1 the offending cupy.cuda.cub module is not built in ROCm/HIP environments, ...
Read more >
CuPy Documentation - Read the Docs
Under AMD ROCm environment, CuPy automatically translates all CUDA API calls to ROCm HIP (hipBLAS, hipFFT,. hipSPARSE, hipRAND, hipCUB ...
Read more >
Arch linux hip error - Blender Stack Exchange
The Arch wiki suggests adding "/opt/rocm/bin/" to your PATH. You could test by running env PATH="${PATH}:/opt/rocm/bin/" blender from the ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found