SWDEV-182753 - Throw error if launch params>bounds

Change-Id: I5f9931efac37e3149894ca116a1b0c2dcc3e5bc5
Este commit está contenido en:
Payam
2021-03-12 19:15:11 -05:00
padre 47e44117cd
commit 2e52ceca29
+7
Ver fichero
@@ -252,6 +252,13 @@ hipError_t ihipModuleLaunchKernel(hipFunction_t f, uint32_t globalWorkSizeX,
return hipErrorInvalidConfiguration;
}
// Make sure the launch params are not larger than if specified launch_bounds
if (blockDimX * blockDimY * blockDimZ > kernel->getDeviceKernel(device)->workGroupInfo()->size_) {
LogPrintfError("%s", "Launch params are larger than launch bounds");
return hipErrorLaunchFailure;
}
if (params & amd::NDRangeKernelCommand::CooperativeGroups) {
if (!device.info().cooperativeGroups_) {
return hipErrorLaunchFailure;