radiance 1.1.1

- Pinned host memory works again on kernel drivers without the SVM API (e.g. a KVM guest with the cards passed through): the host pool is one allocation there instead of 1 GiB pieces that landed apart on the cards (#28). Regression since 1.0.9.
- A host-pool refusal no longer advises shrinking the pool when it fits under the pin cap and the available RAM.
This commit is contained in:
Deadcode committed 2026-10-06 14:43:46 +02:00
1 parent 82b5835c02
commit 7001841e45
5 files changed
+113 -15

No files matched your search

+15
View File
@@ -152,6 +152,21 @@ if(RAD_HIP_FOUND AND TARGET r4d_selftest)
ENVIRONMENT "RADIANCE_HOME=${CMAKE_BINARY_DIR}/radiance_home")
endif()
# ================================================================== the device layer without SVM
#
# A KERNEL DRIVER WITHOUT THE SVM API PINS HOST MEMORY ANOTHER WAY, and a machine with it never
# takes that way. ROCr's thunk maps a locked range in place only through the KFD's SVM API; without
# it (a KVM guest whose amdgpu registered no device memory with HMM) the backend allocates a pinned
# range whole from the host pool (core/device/aql.cpp, "pinned host memory, in pieces"). HSA_USE_SVM=0
# is the thunk's own switch for that driver, so device_test runs a second time under it and the
# path is held on every machine with a card. On the host backend both runs are the same run.
if(RAD_HIP_FOUND AND TARGET device_test)
add_test(NAME device_test_nosvm COMMAND device_test)
set_tests_properties(device_test_nosvm PROPERTIES
SKIP_RETURN_CODE 77
ENVIRONMENT "RADIANCE_HOME=${CMAKE_BINARY_DIR}/radiance_home;HSA_USE_SVM=0")
endif()
# ================================================================== the host kernels
#
# rad-avx-check holds libavx to libref, op for op and at every ISA level the machine executes, and
+2 -1
View File
@@ -164,7 +164,8 @@ TEST(alloc_free_roundtrip) {
* address on the card, copies and fills that cross a piece boundary landing whole, and none of
* them taken for pageable memory -- a fill of pageable memory is refused, so the fill is the
* check. 2.5 GiB is the single-pin size an Intel VT-d host refused; the boundaries crossed are
* the whole GiBs. */
* the whole GiBs. Under HSA_USE_SVM=0 (ctest's device_test_nosvm) the same range is one host-pool
* allocation instead, and the same checks hold it. */
TEST(a_pinned_range_larger_than_one_pin_is_one_range_on_the_card) {
const int64_t gib = (int64_t)1 << 30;
const int64_t n = 5 * (gib / 2) + 4096 + 17;