Fix a crash when printf used in a kernel launched on a stream with custom CU mask

SWDEV-249719 - root cause: queues with custom CU mask are not inserted
into queuePool_ (i.e., queue of reusable HSA queues) of ROC device class
causing a crash when creating hostcall buffers for printf

Change-Id: Ieee7005d9a5a30b3113394ce23ee65927126d0d6
이 커밋은 다음에 포함됨:
Aryan Salmanpour 작성하고 Aryan Salmanpour가 2020-09-25 09:25:19 -04:00를 커밋함
1 부모 0cef35c402
커밋 2e199bd492
3 파일이 변경됨
+27 -12

검색과 일치하는 파일 없음

+2 -2
파일 보기
@@ -761,7 +761,7 @@ VirtualGPU::~VirtualGPU() {
}
if (gpu_queue_) {
roc_device_.releaseQueue(gpu_queue_);
roc_device_.releaseQueue(gpu_queue_, cuMask_);
}
}
@@ -2238,7 +2238,7 @@ bool VirtualGPU::submitKernelInternal(const amd::NDRangeContainer& sizes, const
}
case amd::KernelParameterDescriptor::HiddenHostcallBuffer: {
if (amd::IS_HIP) {
auto buffer = roc_device_.getOrCreateHostcallBuffer(gpu_queue_, coopGroups);
auto buffer = roc_device_.getOrCreateHostcallBuffer(gpu_queue_, coopGroups, cuMask_);
if (!buffer) {
ClPrint(amd::LOG_ERROR, amd::LOG_KERN,
"Kernel expects a hostcall buffer, but none found");