Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Free allocations in unit tests
  • Loading branch information
adrianlizarraga committed Apr 18, 2025
commit 22072493f64eddf75f14fdc33393a8a017ff738c
4 changes: 4 additions & 0 deletions onnxruntime/test/providers/qnn/qnn_ep_context_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,7 @@ TEST_F(QnnHTPBackendTests, CompileApi_FromSessionOptions_OutputModelBuffer) {

// Check that the compiled model has the expected number of EPContext nodes.
CheckEpContextNodeCounts(output_model_buffer, output_model_buffer_size, 2, 2);
allocator.Free(output_model_buffer);
}

// Test using the CompileModel() API with settings:
Expand Down Expand Up @@ -422,6 +423,7 @@ TEST_F(QnnHTPBackendTests, CompileApi_FromSessionOptions_InputAndOutputModelsInB

// Check that the compiled model has the expected number of EPContext nodes.
CheckEpContextNodeCounts(output_model_buffer, output_model_buffer_size, 2, 2);
allocator.Free(output_model_buffer);
}

// Test embed mode disabled.
Expand All @@ -445,6 +447,7 @@ TEST_F(QnnHTPBackendTests, CompileApi_FromSessionOptions_InputAndOutputModelsInB

// Check that the compiled model has the expected number of EPContext nodes.
CheckEpContextNodeCounts(output_model_buffer, output_model_buffer_size, 2, 2);
allocator.Free(output_model_buffer);
}
}

Expand Down Expand Up @@ -495,6 +498,7 @@ TEST_F(QnnHTPBackendTests, CompileApi_FromSessionOptions_OutputModelBuffer_Outpu

// Check that the compiled model has the expected number of EPContext nodes.
CheckEpContextNodeCounts(output_model_buffer, output_model_buffer_size, 2, 2);
allocator.Free(output_model_buffer);
}

// Test that models with 1 non-quantized FusedMatMul node and 1 quantized Add node can still generate the context binary
Expand Down
Loading