SWDEV-530803 - User current device id while cloning graph node. (#313)

This commit is contained in:
Patel, Jaydeepkumar
2025-05-14 20:36:15 -07:00
zatwierdzone przez GitHub
rodzic bddb8f14d1
commit 32eb6a5d89
+2
Wyświetl plik
@@ -271,8 +271,10 @@ bool Graph::TopologicalOrder(std::vector<Node>& TopoOrder) {
// ================================================================================================
void Graph::clone(Graph* newGraph, bool cloneNodes) const {
newGraph->pOriginalGraph_ = this;
auto curDevId = ihipGetDevice();
for (hip::GraphNode* entry : vertices_) {
GraphNode* node = entry->clone();
node->SetDeviceId(curDevId);
node->SetParentGraph(newGraph);
newGraph->vertices_.push_back(node);
newGraph->clonedNodes_[entry] = node;