Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 12 additions & 9 deletions conformance_tests/core/test_module/src/test_module.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1338,25 +1338,28 @@ void zeKernelLaunchTests::RunGivenBufferLargerThan4GBWhenExecutingFunction(
size_t head = 4096;
size_t reference_buffer_size = 4096 * 1024;

LOG_DEBUG << "Memory Properties: " << mem_properties.size();
LOG_DEBUG << "Total available memory: " << total_mem;
LOG_DEBUG << "Available host memory: " << available_host_mem;
LOG_DEBUG << "Max Mem alloc size: " << device_properties.maxMemAllocSize;
LOG_DEBUG << "Allocation size: " << alloc_size;
LOG_INFO << "Memory Properties: " << mem_properties.size();
LOG_INFO << "Total device memory: " << total_mem;
LOG_INFO << "Available host memory: " << available_host_mem;
LOG_INFO << "Max Mem alloc size: " << device_properties.maxMemAllocSize;
LOG_INFO << "Allocation size: " << alloc_size;

if (alloc_size > available_host_mem) {
GTEST_SKIP() << "Required allocation size is greater than available host "
"memory, skipping test";
}

if (alloc_size > mem_properties[0].totalSize) {
if (alloc_size > device_properties.maxMemAllocSize) {
GTEST_SKIP()
<< "Required allocation size is greater than max allocation size, "
"skipping test";
}

if (alloc_size > total_mem) {
GTEST_SKIP() << "Required allocation size is greater than total memory, "
"skipping test";
}

size_t difference =
mem_properties[0].totalSize - device_properties.maxMemAllocSize;

uint8_t *reference_buffer, *head_buffer;
try {
reference_buffer = new uint8_t[reference_buffer_size];
Expand Down
Loading