Page MenuHomeSolus

Initial commit of rocm-hip for T6614
ClosedPublic

Authored by Jacek on Apr 25 2022, 12:30 AM.
Tags
None
Referenced Files
F11023994: D13172.diff
Tue, Aug 8, 6:18 PM
F11022554: D13172.id32218.diff
Tue, Aug 8, 2:26 AM
F11021698: D13172.id32497.diff
Mon, Aug 7, 4:47 PM
F11021518: D13172.id32320.diff
Mon, Aug 7, 3:18 PM
F11021438: D13172.id32218.diff
Mon, Aug 7, 2:30 PM
F11020472: D13172.id32605.diff
Mon, Aug 7, 5:36 AM
F11019234: D13172.id32257.diff
Sun, Aug 6, 6:29 PM
F11015915: D13172.id32649.diff
Sat, Aug 5, 3:08 PM

Details

Summary

For T6614
Depends on D13168

Test Plan

Successfully built rocBLAS against it

Diff Detail

Branch
master
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 3784
Build 3784: arc lint + arc unit

Event Timeline

Actually add all the files to the repo

Remove .gitignore, really sorry about spamming

Rework build script so it doesn't require downloading ROCclr and OpenCL-Runtime again

@Jacek replace Relies on with Depends on to make rocm stack.

Girtablulu added a subscriber: Girtablulu.

as well, for what the ls commands is needed? and what algent said

package.yml
14 ↗(On Diff #32195)

check for pkgconfig

This revision now requires changes to proceed.Apr 27 2022, 9:41 AM

Add MAINTAINERS.md and remove lses

Arrange build deps in alphabetical order ;)

Update sources to be used with patched solbuild

Simplify build with standalone build of ROCClr

Jacek marked an inline comment as done.

Remove builddeps no longer needed after moving to standalone ROCclr

This revision is now accepted and ready to land.May 22 2022, 1:38 PM

Make hip-config.cmake less broken, allowing to build stuff that relies on hip

Change ROCM_DIR to ROCM_PATH

Adopt patches from Debian to unbork .cmake files even more

Make hip build use static rocclr
This means I have to include all the patches and sources of -opencl, but there is no other way until upstream changes its approach

Update to 5.1.3, remove use of __noinline__ which broke compatibility with newer GCC

Don't specify for which architecture to build

Jacek retitled this revision from [RFC] Initial commit of rocm-hip for T6614 to Initial commit of rocm-hip for T6614.

edit: Well you can ignore this now :D

Can you update the test plan? Either with an application or you could consider converting this cuda sample to hip for example https://github.com/ROCm-Developer-Tools/HIP/tree/develop/samples/0_Intro/square

Can you update the test plan? Either with an application or you could consider converting this cuda sample to hip for example https://github.com/ROCm-Developer-Tools/HIP/tree/develop/samples/0_Intro/square

I managed to build rocBLAS, which is a complex package, that builds a separate kernel for each supported GPU architecture, the whole build took 2 hours. For now I don't have time to test anything else, I am leaving for a week. Best test would be to test Blender if it works with HIP, once it gets updated to 3.2.
If you think it is not enough testing, could you accept the entire rest of ROCm for OpenCL support, and -HIP could wait? But I would love if -HIP got into the repo, nothing suggests it is in any way broken, and packages could be build against it when needed.

This revision was automatically updated to reflect the committed changes.

Not yet included in repo - waiting on rocm-opencl.

Also pushed this now that there are no more blockers.

It currently builds fine locally for me.

I vaguely remember when I packaged ROCm for my personal repo I had to switch the build order around and/or added some dependencies, but I forgot which...

@Staudey Maybe cleaning the cache and rebuilding could work? I tried several times, both building against Unstable and also my personal repo, and all succeeded. However, I do get a very long pause around the line that broke:

-- Found HIP: /home/build/YPKG/root/rocm-hip/build/hipamd-rocm-5.1.3/build (found version "5.1.0") 
-- Performing Test HIP_CLANG_SUPPORTS_PARALLEL_JOBS
-- Performing Test HIP_CLANG_SUPPORTS_PARALLEL_JOBS - Failed
-- host interface - found
-- HIP runtime lib type - shared
-- CMAKE_TESTING_TOOL: 
-- CMAKE HIP ARCHITECTURES: OFF
-- ROCm Agent Enumurator Result: 0
-- Using offload arch string:   --offload-arch=gfx1032
# Pauses for almost a minute!

FileNotFoundError: [Errno 2] No such file or directory: '/sys/class/kfd/kfd/topology/nodes/' does this path only exist if you have AMD hardware installed?

Most likely failing as cmake has been updated since this was initially landed.

@joebonrichie @GZGavinZhao You guys are amazing! Thank you so much for fixing it so quickly, while I was sleeping ;) And yes, rocm-opencl works just fine, and I can build rocBLAS with rocm-hip, so this seems to be working just fine too. Thanks for your amazing job!