SWDEV-439637 - Updated to compile with clang compiler

Change-Id: Ib0a8e1cc007f083fb1d1f4363cf89ba76ad3c4f2
This commit is contained in:
Anusha GodavarthySurya
2024-01-02 14:56:03 +00:00
zatwierdzone przez Anusha Godavarthy Surya
rodzic e37aaeae09
commit a1b2cbe44e
6 zmienionych plików z 106 dodań i 96 usunięć
+13 -15
Wyświetl plik
@@ -2295,21 +2295,19 @@ hipError_t hipGraphExecUpdate(hipGraphExec_t hGraphExec, hipGraph_t hGraph,
}
}
switch(newGraphNodes[i]->GetType()) {
case hipGraphNodeTypeMemcpy: {
// Checks if the memcpy node's parameters are same
const hip::GraphMemcpyNode* newMemcpyNode =
static_cast<hip::GraphMemcpyNode const*>(newGraphNodes[i]);
const hip::GraphMemcpyNode* oldMemcpyNode =
static_cast<hip::GraphMemcpyNode const*>(oldGraphExecNodes[i]);
hipMemcpyKind newKind, oldKind;
newKind = newMemcpyNode->GetMemcpyKind();
oldKind = oldMemcpyNode->GetMemcpyKind();
if (newKind != oldKind) {
*hErrorNode_out = reinterpret_cast<hipGraphNode_t>(newGraphNodes[i]);
*updateResult_out = hipGraphExecUpdateErrorParametersChanged;
HIP_RETURN(hipErrorGraphExecUpdateFailure);
}
if (newGraphNodes[i]->GetType() == hipGraphNodeTypeMemcpy) {
// Checks if the memcpy node's parameters are same
const hip::GraphMemcpyNode* newMemcpyNode =
static_cast<hip::GraphMemcpyNode const*>(newGraphNodes[i]);
const hip::GraphMemcpyNode* oldMemcpyNode =
static_cast<hip::GraphMemcpyNode const*>(oldGraphExecNodes[i]);
hipMemcpyKind newKind, oldKind;
newKind = newMemcpyNode->GetMemcpyKind();
oldKind = oldMemcpyNode->GetMemcpyKind();
if (newKind != oldKind) {
*hErrorNode_out = reinterpret_cast<hipGraphNode_t>(newGraphNodes[i]);
*updateResult_out = hipGraphExecUpdateErrorParametersChanged;
HIP_RETURN(hipErrorGraphExecUpdateFailure);
}
}
// Checks if all the node's dependencies are same