SWDEV-469422 - hipGraph move to classes from structs

Change-Id: I0f9c8ef1161c0c92ebe0cce6844b2feacfee83f5
Tá an tiomantas seo le fáil i:
Anusha GodavarthySurya
2025-01-17 09:10:35 +00:00
tiomanta ag Anusha Godavarthy Surya
tuismitheoir 29cc394510
tiomantas 32e5b00c30
D'athraigh 3 comhad le 108 breiseanna agus 99 scriosta
+4 -4
Féach ar an gComhad
@@ -1601,7 +1601,7 @@ hipError_t hipGraphLaunch_common(hip::GraphExec* graphExec, hipStream_t stream)
if (graphExec == nullptr || !hip::GraphExec::isGraphExecValid(graphExec)) {
return hipErrorInvalidValue;
}
if (graphExec->clonedNodes_.empty()) {
if (graphExec->GetNodeCount() == 0) {
return hipSuccess;
}
if (!hip::isValid(stream)) {
@@ -2286,7 +2286,7 @@ hipError_t hipGraphClone(hipGraph_t* pGraphClone, hipGraph_t originalGraph) {
if (!hip::Graph::isGraphValid(g)) {
HIP_RETURN(hipErrorInvalidValue);
}
for (auto n : g->vertices_) {
for (auto n : g->GetNodes()) {
if (n->GetType() == hipGraphNodeTypeMemAlloc ||
n->GetType() == hipGraphNodeTypeMemFree) {
HIP_RETURN(hipErrorNotSupported);
@@ -2664,8 +2664,8 @@ hipError_t hipGraphExecUpdate(hipGraphExec_t hGraphExec, hipGraph_t hGraph,
if (newGraphNodes[i]->GetType() == oldGraphExecNodes[i]->GetType()) {
if (newGraphNodes[i]->GetType() != hipGraphNodeTypeHost &&
newGraphNodes[i]->GetType() != hipGraphNodeTypeEmpty) {
if (newGraphNodes[i]->GetParentGraph()->device_ !=
oldGraphExecNodes[i]->GetParentGraph()->device_) {
if (newGraphNodes[i]->GetParentGraph()->Device() !=
oldGraphExecNodes[i]->GetParentGraph()->Device()) {
*updateResult_out = hipGraphExecUpdateErrorUnsupportedFunctionChange;
*hErrorNode_out = reinterpret_cast<hipGraphNode_t>(newGraphNodes[i]);
return hipErrorGraphExecUpdateFailure;