I had a look at TheRock
Hello,
i had a look at how https://github.com/ROCm/TheRock is building ROCm
I found this interesting and share ...
To build it is required to install
gfortran git git-lfs ninja-build cmake g++ pkg-config xxd patchelf
automake libtool python3-venv python3-dev libegl1-mesa-dev
I used an Ubuntu 24.04 container with these dependencies
to see how all of this builds.
First of all you have to build a virtualenv with the following requirements
CppHeaderParser>=2.7.4
build>=1.2.2
meson>=1.7.0
python-magic>=0.4.27
PyYAML==6.0.2
tomli==2.2.1; python_version <= '3.10'
# hipBLASLt deps
joblib>=1.4.2
msgpack>=1.1.0
except CppHeaderParser all the packages are available in debian
c++headerparser seems very similar to CppHeaderParser
I wonder if it would be of some help to package CppHeaderParser or
if c++headerparser is enough.
I also wonder what is the impact of the trixie python3.13 ...
After the pre-configuring steps with ccache I started the build
with THEROCK_AMDGPU_FAMILIES=gfx110X-dgpu
And then a second build, that build nothing, since it's already done
But provide some log I found interesting
Here is how the build looks like
(I made some cleanup and reformating to make this more readeable)
==============================================================
cmake --build build
[0/2] Re-checking globbed directories...
-- GLOB mismatch!
[1/2] Re-running CMake...
-- Configuring background job pool for 12 concurrent jobs
-- Enabling building tests
-- ROCm version: 7.0.0
-- HIP version: 6.5.0
-- Implicitly enabled features: HOST_SUITE_SPARSE HOST_BLAS
-- Enabled features:
-- * HOST_BLAS (-DTHEROCK_ENABLE_HOST_BLAS=ON)
-- * HOST_SUITE_SPARSE (-DTHEROCK_ENABLE_HOST_SUITE_SPARSE=ON)
-- * COMPILER (-DTHEROCK_ENABLE_COMPILER=ON)
-- * HIPIFY (-DTHEROCK_ENABLE_HIPIFY=ON)
-- * CORE_RUNTIME (-DTHEROCK_ENABLE_CORE_RUNTIME=ON)
-- * HIP_RUNTIME (-DTHEROCK_ENABLE_HIP_RUNTIME=ON)
-- * ROCPROF_TRACE_DECODER_BINARY
(-DTHEROCK_ENABLE_ROCPROF_TRACE_DECODER_BINARY=ON)
-- * ROCPROFV3 (-DTHEROCK_ENABLE_ROCPROFV3=ON)
-- * RCCL (-DTHEROCK_ENABLE_RCCL=ON)
-- * PRIM (-DTHEROCK_ENABLE_PRIM=ON)
-- * BLAS (-DTHEROCK_ENABLE_BLAS=ON)
-- * RAND (-DTHEROCK_ENABLE_RAND=ON)
-- * FFT (-DTHEROCK_ENABLE_FFT=ON)
-- * SPARSE (-DTHEROCK_ENABLE_SPARSE=ON)
-- * SOLVER (-DTHEROCK_ENABLE_SOLVER=ON)
-- * COMPOSABLE_KERNEL (-DTHEROCK_ENABLE_COMPOSABLE_KERNEL=ON)
-- * MIOPEN (-DTHEROCK_ENABLE_MIOPEN=ON)
-- Configured AMDGPU Targets:
-- * gfx1100 : AMD RX 7900 XTX
-- * gfx1101 : AMD RX 7800 XT
-- * gfx1102 : AMD RX 7700S/Framework Laptop 16
-- * Dist bundle: gfx110X-dgpu
-- Building with bundled system dependencies enabled
====== THIRD PARTY ======
-- Including subproject therock-boost
(from .../third-party/boost/cmake_project)
-- Including subproject therock-eigen
(from .../third-party/eigen/source)
-- Including subproject therock-fmt
(from .../third-party/fmt/source)
-- Including subproject therock-googletest
(from ../third-party/googletest/source)
-- Including subproject therock-libdivide
(from .../third-party/libdivide/source)
-- Including subproject therock-msgpack-cxx
(from .../third-party/msgpack-cxx/source)
-- Including subproject therock-nlohmann-json
(from .../third-party/nlohmann-json/source)
-- Including subproject therock-yaml-cpp
(from .../third-party/yaml-cpp/source)
-- Including subproject therock-catch2
(from .../third-party/Catch2/source)
-- Including subproject therock-FunctionalPlus
(from .../third-party/FunctionalPlus/source)
-- Including subproject therock-frugally-deep
(from .../third-party/frugally-deep/source)
-- Including subproject therock-spdlog
(from .../third-party/spdlog/source)
-- Including subproject therock-host-blas
(from .../third-party/host-blas/.)
-- Including subproject therock-SuiteSparse
(from .../third-party/SuiteSparse/source)
-- Including subproject therock-bzip2
(from .../third-party/sysdeps/common/bzip2/.)
-- Including subproject therock-libdrm
(from .../third-party/sysdeps/linux/libdrm/.)
-- Including subproject therock-numactl
(from .../third-party/sysdeps/linux/numactl/.)
-- Including subproject therock-sqlite3
(from .../third-party/sysdeps/common/sqlite3/.)
-- Including subproject therock-zlib
(from .../third-party/sysdeps/common/zlib/.)
-- Including subproject therock-zstd
(from .../third-party/sysdeps/common/zstd/.)
-- Including subproject therock-elfutils
(from .../third-party/sysdeps/linux/elfutils/.)
I just wonder why rebuild some libs that seems really common and not
just apt install
===== BASE =====
-- Including subproject therock-aux-overlay
(from .../base/aux-overlay)
-- Including subproject rocm-cmake
(from .../base/rocm-cmake)
-- Including subproject rocm-core
(from .../base/rocm-core)
-- Including subproject rocm_smi_lib
(from .../base/rocm_smi_lib)
-- Including subproject rocprofiler-register
(from .../base/rocprofiler-register)
-- Including subproject rocm-half
(from .../base/half)
===== COMPILER =====
-- Including subproject amd-llvm
(from .../compiler/amd-llvm/llvm)
-- Including subproject amd-comgr
(from .../compiler/amd-llvm/amd/comgr)
-- Including subproject hipcc
(from .../compiler/amd-llvm/amd/hipcc)
-- Including subproject hipify
(from .../compiler/hipify)
===== CORE =====
-- Including subproject ROCR-Runtime
(from .../core/ROCR-Runtime)
-- Including subproject rocminfo
(from .../core/rocminfo)
-- Including subproject hip-clr
(from .../core/clr)
===== PROFILER =====
-- Including subproject rocprof-trace-decoder
(from .../profiler/rocprof-trace-decoder)
-- Including subproject aqlprofile
(from .../profiler/aqlprofile)
-- Including subproject rocprofiler-sdk
(from .../profiler/rocprofiler-sdk)
-- Including subproject roctracer
(from .../profiler/roctracer)
===== COMM-LIBS =====
-- Including subproject rccl
(from .../comm-libs/rccl)
-- Including subproject rccl-tests
(from .../comm-libs/rccl-tests)
===== MATH-LIBS =====
-- Including subproject rocRAND
(from .../math-libs/rocRAND)
-- Including subproject hipRAND
(from .../math-libs/hipRAND)
-- Including subproject rocPRIM
(from .../math-libs/rocPRIM)
-- Including subproject hipCUB
(from .../math-libs/hipCUB)
-- Including subproject rocThrust
(from .../math-libs/rocThrust)
-- Including subproject rocFFT
(from .../math-libs/rocFFT)
-- Including subproject hipFFT
(from .../math-libs/hipFFT)
-- Including subproject mxDataGenerator
(from .../math-libs/support/mxDataGenerator)
-- Including subproject hipBLAS-common
(from .../math-libs/BLAS/hipBLAS-common)
-- Including subproject rocRoller
(from .../math-libs/BLAS/rocRoller/next-cmake)
-- Including subproject hipBLASLt
(from .../math-libs/BLAS/hipBLASLt/next-cmake)
-- Including subproject rocBLAS
(from .../math-libs/BLAS/rocBLAS)
-- Including subproject rocSPARSE
(from .../math-libs/BLAS/rocSPARSE)
-- Including subproject hipSPARSE
(from .../math-libs/BLAS/hipSPARSE)
-- Including subproject rocSOLVER
(from .../math-libs/BLAS/rocSOLVER)
-- Including subproject hipSOLVER
(from .../math-libs/BLAS/hipSOLVER)
-- Including subproject hipBLAS
(from .../math-libs/BLAS/hipBLAS)
===== ML-LIBS =====
-- Including subproject composable_kernel
(from .../ml-libs/composable_kernel)
-- Including subproject MIOpen
(from .../ml-libs/MIOpen)
===================
-- Setting up compile_commands.json export
-- Configuring done (35.9s)
-- Generating done (1.7s)
-- Build files have been written to: .../build
[0/2] Re-checking globbed directories...
[1/1] Merging compile_commands.json
Here is what i've seen at the moment,
I intent to try to build with a trixie container, but needs to
understand a bit more cmake before to remove if possible at least some
third party ...
I think it could be interesting to have this in a corner, to test how
different can be the perf with the debian build
The is also a pytorch build i'd like to understand ...
Christian B.
Reply to: