ROCm / MIOpen

AMD's Machine Intelligence Library
https://rocm.docs.amd.com/projects/MIOpen/en/latest/
Other
1.09k stars 230 forks source link

rocrand/rocrand_xorwow.h used without including /opt/rocm/include #3314

Open lamb-j opened 1 month ago

lamb-j commented 1 month ago

https://github.com/ROCm/MIOpen/blob/31ba13d440e8d5580c1196984ead28afaf80d0b3/src/kernels/miopen_rocrand.hpp#L45

Currently, this header file is included inside some MIOpen kernel calls, but the path to this header is not included as a command line include.

In the past, this worked without issues because hipRTC/Comgr automatically added -I /opt/rocm/include to kernel compilations. However, this behavior is being removed, as hipRTC has no guarantees about a system ROCm installation during kernel compilation/execution.

This leads to issues like the following:

In file included from /tmp/comgr-92ff79/input/MIOpenSoftmaxAttn.cpp:38:
/tmp/comgr-92ff79/include/miopen_rocrand.hpp:45:10: fatal error: 'rocrand/rocrand_xorwow.h' file not found
   45 | #include <rocrand/rocrand_xorwow.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated when compiling for gfx1030.

To fix this, MIOpen should include the path to the directory containing rocrand/rocrand_xorwow.h when compiling.

lamb-j commented 2 weeks ago

Any progress/ideas/thoughts on this one? It is still blocking a major Comgr update.