mgpusim icon indicating copy to clipboard operation
mgpusim copied to clipboard

Support HIP, as well as OpenCL kernels compiled by new ROCm versions

Open syifan opened this issue 1 year ago • 7 comments

Is your feature request related to a problem? Please describe. Currently, we can only support OpenCL kernel compiled with ROCm 3.8, which is very old.

Describe the solution you'd like We need to support the new ABI of the code object v3, which is described here https://llvm.org/docs/AMDGPUUsage.html#kernel-descriptor

syifan avatar Jan 16 '24 17:01 syifan

Hello author, I modified the kernel. cl file of AES a few days ago, but it cannot run after recompiling. I have been testing these days and have downloaded mgpusim again. I used interCPU and also installed ROCm-dev. Afterwards, I only deleted the original kernels.hsaco and kernels.disasm in AES. After recompiling with the clang-ocl command, it did not run correctly. What tools should I use to correctly compile kernel functions to generate HSACO files. Looking forward to your reply! QQ20240419-170247

Yzgll avatar Apr 19 '24 09:04 Yzgll

Hello author, I modified the kernel. cl file of AES a few days ago, but it cannot run after recompiling. I have been testing these days and have downloaded mgpusim again. I used interCPU and also installed ROCm-dev. Afterwards, I only deleted the original kernels.hsaco and kernels.disasm in AES. After recompiling with the clang-ocl command, it did not run correctly. What tools should I use to correctly compile kernel functions to generate HSACO files. Looking forward to your reply! QQ20240419-170247

It looks like that an instruction is not implemented. This is not because you used the wrong compilder, but because our simulator does not support the instruction. Can you add the instruction implementation?

syifan avatar Apr 19 '24 15:04 syifan

Hello author, I modified the kernel. cl file of AES a few days ago, but it cannot run after recompiling. I have been testing these days and have downloaded mgpusim again. I used interCPU and also installed ROCm-dev. Afterwards, I only deleted the original kernels.hsaco and kernels.disasm in AES. After recompiling with the clang-ocl command, it did not run correctly. What tools should I use to correctly compile kernel functions to generate HSACO files. Looking forward to your reply! QQ20240419-170247

It looks like that an instruction is not implemented. This is not because you used the wrong compilder, but because our simulator does not support the instruction. Can you add the instruction implementation?

Thank you for your reply. I will try my best

Yzgll avatar Apr 20 '24 10:04 Yzgll