graphConditionalNodes: Additional tweaks to launch dimension initialization (#348)

This commit is contained in:
Rob Armstrong 2025-03-05 18:17:27 -08:00 committed by GitHub
parent 990ebc01c2
commit 291435e0b4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -95,8 +95,8 @@ void simpleIfGraph(void)
// Use a kernel upstream of the conditional to set the handle value
cudaGraphNodeParams params = {cudaGraphNodeTypeKernel};
params.kernel.func = (void *)ifGraphKernelA;
params.kernel.gridDim = 1;
params.kernel.blockDim = 1;
params.kernel.blockDim.x = params.kernel.blockDim.y = params.kernel.blockDim.z = 1;
params.kernel.gridDim.x = params.kernel.gridDim.y = params.kernel.gridDim.z = 1;
params.kernel.kernelParams = kernelArgs;
kernelArgs[0] = &dPtr;
kernelArgs[1] = &handle;
@ -496,8 +496,8 @@ void simpleSwitchGraph(void)
// Use a kernel upstream of the conditional to set the handle value
cudaGraphNodeParams params = {cudaGraphNodeTypeKernel};
params.kernel.func = (void *)switchGraphKernelA;
params.kernel.gridDim = 1;
params.kernel.blockDim = 1;
params.kernel.blockDim.x = params.kernel.blockDim.y = params.kernel.blockDim.z = 1;
params.kernel.gridDim.x = params.kernel.gridDim.y = params.kernel.gridDim.z = 1;
params.kernel.kernelParams = kernelArgs;
kernelArgs[0] = &dPtr;
kernelArgs[1] = &handle;