SWDEV-419996 - Allow both kernelParams and extra arguments to be set to null
When kernel function expects no parameters no error should be returned if both kernelParams and extra arguments are set to null. Change-Id: I5941bcc400b6fb380e623bdae0233ae3e4f73815
This commit is contained in:
@@ -76,12 +76,6 @@ hipError_t ihipGraphAddKernelNode(hip::GraphNode** pGraphNode, hip::Graph* graph
|
||||
return hipErrorInvalidValue;
|
||||
}
|
||||
|
||||
// If neither 'kernelParams' or 'extra' are provided or if both are provided, return error
|
||||
if ((pNodeParams->kernelParams == nullptr && pNodeParams->extra == nullptr) ||
|
||||
(pNodeParams->kernelParams != nullptr && pNodeParams->extra != nullptr)) {
|
||||
return hipErrorInvalidValue;
|
||||
}
|
||||
|
||||
hipError_t status = hip::GraphKernelNode::validateKernelParams(pNodeParams);
|
||||
if (hipSuccess != status) {
|
||||
return status;
|
||||
|
||||
Reference in New Issue
Block a user