Skip to content

Commit e304022

Browse files
committed
minor changes
1 parent 301ddd6 commit e304022

3 files changed

Lines changed: 10 additions & 1 deletion

File tree

backends/qualcomm/runtime/backends/QnnProfiler.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ Qnn_ErrorHandle_t QnnProfile::ProfileDataToFile(
254254
"Not HTP backend but enable htp profiling. Please check setting.");
255255
return QNN_SUCCESS;
256256
}
257-
return error;
257+
return QNN_SUCCESS;
258258
}
259259

260260
QnnProfile::~QnnProfile() {

backends/qualcomm/runtime/backends/htp/HtpContextCustomConfig.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ class HtpContextCustomConfig {
3535
std::vector<QnnContext_CustomConfig_t> CreateContextCustomConfig();
3636

3737
private:
38+
// profile_level_ is consumed only by the target build; the host build never
39+
// reads it. Marked [[maybe_unused]] so the host build doesn't warn while the
40+
// field stays available for the target side.
3841
[[maybe_unused]] QnnExecuTorchProfileLevel profile_level_;
3942
QnnHtpContext_CustomConfig_t* AllocContextCustomConfig() {
4043
htp_context_config_.emplace_back(

backends/qualcomm/tests/utils.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -432,6 +432,12 @@ def validate_heap_profile():
432432
print(f"after_context_freed: {after} bytes")
433433
print(f"difference: {difference:.2f} bytes")
434434

435+
self.assertGreaterEqual(
436+
after,
437+
before,
438+
"after_context_freed should be >= before_context_created",
439+
)
440+
435441
def validate_intermediate_tensor():
436442
qnn_intermediate_debugger.setup_inspector(
437443
etdump_path=etdump_path,

0 commit comments

Comments
 (0)