Bug 5150289: Waive the sample for unsupported SM arch

This commit is contained in:
shawnz 2025-08-12 19:18:23 +08:00
parent 5fc7a4c897
commit 6e23a98575

View File

@ -100,6 +100,18 @@ int main()
int rc;
cudaFree(0);
// Check compute capability - large kernel parameters require SM 7.0+
cudaDeviceProp deviceProp;
int devID;
checkCudaErrors(cudaGetDevice(&devID));
checkCudaErrors(cudaGetDeviceProperties(&deviceProp, devID));
if (deviceProp.major < 7) {
printf("LargeKernelParameter requires SM 7.0 or higher. Exiting...\n");
printf("Current device: %s (SM %d.%d)\n", deviceProp.name, deviceProp.major, deviceProp.minor);
exit(EXIT_WAIVED);
}
param_t p;
param_large_t p_large;