summaryrefslogtreecommitdiff
path: root/dev-libs
diff options
context:
space:
mode:
Diffstat (limited to 'dev-libs')
-rw-r--r--dev-libs/rccl/files/rccl-10.1.0-llvm-23-gfx942.patch19
-rw-r--r--dev-libs/rccl/rccl-10.1.0.ebuild1
-rw-r--r--dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-10.1.0-r1.ebuild (renamed from dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-10.1.0.ebuild)6
-rw-r--r--dev-libs/roct-thunk-interface/roct-thunk-interface-10.1.0.ebuild6
4 files changed, 31 insertions, 1 deletions
diff --git a/dev-libs/rccl/files/rccl-10.1.0-llvm-23-gfx942.patch b/dev-libs/rccl/files/rccl-10.1.0-llvm-23-gfx942.patch
new file mode 100644
index 000000000000..8c391212936c
--- /dev/null
+++ b/dev-libs/rccl/files/rccl-10.1.0-llvm-23-gfx942.patch
@@ -0,0 +1,19 @@
+Fix build with LLVM 23 for gfx942 and gfx950
+
+LLVM 23 fails with "Cannot scavenge register in FI elimination" on some
+kernels (fixed by llvm/llvm-project@c003bfba6158); together, disabling the
+machine scheduler and the basic SGPR allocator avoid it.
+
+Bug: https://bugs.gentoo.org/984543
+--- a/cmake/DeviceLinker.cmake
++++ b/cmake/DeviceLinker.cmake
+@@ -288,6 +288,9 @@ foreach(DL_GPU_TARGET ${DL_GPU_TARGETS})
+ -fPIC
+ ${DL_INHERITED_FLAGS}
+ )
++ if(DL_GPU_TARGET MATCHES "^gfx9(42|50)$")
++ target_compile_options(${_dev_target} PRIVATE -mllvm=-enable-misched=false -mllvm=-sgpr-regalloc=basic)
++ endif()
+ target_compile_definitions(${_dev_target} PRIVATE RCCL_DEVICE_LINKER)
+ target_link_libraries(${_dev_target} PRIVATE rccl_device_defs)
+
diff --git a/dev-libs/rccl/rccl-10.1.0.ebuild b/dev-libs/rccl/rccl-10.1.0.ebuild
index 8cae2c180efc..7cb807abb404 100644
--- a/dev-libs/rccl/rccl-10.1.0.ebuild
+++ b/dev-libs/rccl/rccl-10.1.0.ebuild
@@ -48,6 +48,7 @@ RESTRICT="!test? ( test )"
PATCHES=(
"${FILESDIR}"/${P}-no-roctx.patch
+ "${FILESDIR}"/${P}-llvm-23-gfx942.patch
)
src_prepare() {
diff --git a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-10.1.0.ebuild b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-10.1.0-r1.ebuild
index 797a3cde48e4..2d253cbb8659 100644
--- a/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-10.1.0.ebuild
+++ b/dev-libs/rocm-opencl-runtime/rocm-opencl-runtime-10.1.0-r1.ebuild
@@ -66,6 +66,12 @@ src_configure() {
append-flags -fno-strict-aliasing
filter-lto
+ use debug && CMAKE_BUILD_TYPE="Debug"
+ # upstream release builds have assertions disabled; some are reachable
+ # (e.g. Isa::isCompatible on gfx90c), aborting otherwise working programs
+ # Bug: https://bugs.gentoo.org/984577
+ use debug || append-cppflags -DNDEBUG
+
# Fix ld.lld linker error: https://github.com/RadeonOpenCompute/ROCm-OpenCL-Runtime/issues/155
append-ldflags $(test-flags-CCLD -Wl,--undefined-version)
diff --git a/dev-libs/roct-thunk-interface/roct-thunk-interface-10.1.0.ebuild b/dev-libs/roct-thunk-interface/roct-thunk-interface-10.1.0.ebuild
index 8f05341deba2..21abeea777e9 100644
--- a/dev-libs/roct-thunk-interface/roct-thunk-interface-10.1.0.ebuild
+++ b/dev-libs/roct-thunk-interface/roct-thunk-interface-10.1.0.ebuild
@@ -88,6 +88,10 @@ src_configure() {
filter-lto
export LIBHSAKMT_PATH="${BUILD_DIR}"
+ mycmakeargs+=(
+ -DCMAKE_DISABLE_FIND_PACKAGE_hsakmt=ON
+ -DHSAKMT_LIBRARY="${BUILD_DIR}/libhsakmt.so"
+ )
test_wrapper "${S}/tests/kfdtest" cmake_src_configure
fi
}
@@ -125,5 +129,5 @@ src_test() {
KFDQMTest.QueueLatency
)
local IFS=:
- ./run_kfdtest.sh -e "${skipped_tests[*]}" || die
+ LD_LIBRARY_PATH="${BUILD_DIR}" ./run_kfdtest.sh -e "${skipped_tests[*]}" || die
}