Skip to content

Commit

Permalink
Fix v1 adapter implementation of the spill memory size kernel propert…
Browse files Browse the repository at this point in the history
…y query for multi-device systems
  • Loading branch information
kurapov-peter committed Feb 18, 2025
1 parent 2606219 commit 198a7a1
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions source/adapters/level_zero/kernel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -752,8 +752,11 @@ ur_result_t urKernelGetInfo(
case UR_KERNEL_INFO_NUM_ARGS:
return ReturnValue(uint32_t{Kernel->ZeKernelProperties->numKernelArgs});
case UR_KERNEL_INFO_SPILL_MEM_SIZE: {
std::vector<uint32_t> spills = {
uint32_t{Kernel->ZeKernelProperties->spillMemSize}};
std::vector<uint32_t> spills;
spills.reserve(Kernel->ZeKernels.size());
for (const auto *K : Kernel->ZeKernels()) {
spills.push_back(K->ZeKernelProperties->spillMemSize);
}
return ReturnValue(static_cast<const uint32_t *>(spills.data()),
spills.size());
}
Expand Down

0 comments on commit 198a7a1

Please sign in to comment.