SWDEV-252801 - Fail if launch params exceeds launch_bounds

Change-Id: I90c8d0f1897ca63f00c3eec7c99d649a5c43416d


[ROCm/hip commit: 2b04d249fc]
Этот коммит содержится в:
Maneesh Gupta
2021-05-06 22:38:50 -07:00
родитель 4835549bd8
Коммит a486ce6f0c
+3 -2
Просмотреть файл
@@ -244,10 +244,11 @@ inline hipError_t ihipLaunchKernel_validate(hipFunction_t f, uint32_t globalWork
hip::DeviceFunc* function = hip::DeviceFunc::asFunction(f);
amd::Kernel* kernel = function->kernel();
// Make sure the launch params are not larger than if specified launch_bounds
// If it exceeds, then print a warning and continue for now
// If it exceeds, then return a failure
if (blockDimX * blockDimY * blockDimZ >
kernel->getDeviceKernel(*device)->workGroupInfo()->size_) {
LogPrintfWarning("%s", "Launch params are larger than launch bounds");
LogPrintfError("%s", "Launch params are larger than launch bounds");
return hipErrorLaunchFailure;
}
if (params & amd::NDRangeKernelCommand::CooperativeGroups) {