mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-06-07 00:13:17 +00:00
### Description
<!-- Describe your changes. -->
This reverts commit 5d215ff810.
### Motivation and Context
<!-- - Why is this change required? What problem does it solve?
- If it fixes an open issue, please link to the issue here. -->
The reverted change causes a packaging pipeline to fail due to a crash
in one of the E2E Android tests.
Reverting this first to fix the pipeline. We should come up with an
alternative way to properly do the necessary clean up.
This commit is contained in:
parent
ad312d9677
commit
db8e10b0b9
1 changed files with 10 additions and 6 deletions
|
|
@ -1097,35 +1097,39 @@ Status QnnBackendManager::TerminateQnnLog() {
|
|||
}
|
||||
|
||||
void QnnBackendManager::ReleaseResources() {
|
||||
if (!backend_setup_completed_) {
|
||||
return;
|
||||
}
|
||||
|
||||
auto result = ReleaseContext();
|
||||
if (Status::OK() != result) {
|
||||
LOGS_DEFAULT(ERROR) << "Failed to ReleaseContext: " << result.ErrorMessage();
|
||||
LOGS_DEFAULT(ERROR) << "Failed to ReleaseContext.";
|
||||
}
|
||||
|
||||
result = ReleaseProfilehandle();
|
||||
if (Status::OK() != result) {
|
||||
LOGS_DEFAULT(ERROR) << "Failed to ReleaseProfilehandle: " << result.ErrorMessage();
|
||||
LOGS_DEFAULT(ERROR) << "Failed to ReleaseProfilehandle.";
|
||||
}
|
||||
|
||||
result = ReleaseDevice();
|
||||
if (Status::OK() != result) {
|
||||
LOGS_DEFAULT(ERROR) << "Failed to ReleaseDevice: " << result.ErrorMessage();
|
||||
LOGS_DEFAULT(ERROR) << "Failed to ReleaseDevice.";
|
||||
}
|
||||
|
||||
result = ShutdownBackend();
|
||||
if (Status::OK() != result) {
|
||||
LOGS_DEFAULT(ERROR) << "Failed to ShutdownBackend: " << result.ErrorMessage();
|
||||
LOGS_DEFAULT(ERROR) << "Failed to ShutdownBackend.";
|
||||
}
|
||||
|
||||
result = TerminateQnnLog();
|
||||
if (Status::OK() != result) {
|
||||
LOGS_DEFAULT(ERROR) << "Failed to TerminateQnnLog: " << result.ErrorMessage();
|
||||
LOGS_DEFAULT(ERROR) << "Failed to TerminateQnnLog.";
|
||||
}
|
||||
|
||||
if (backend_lib_handle_) {
|
||||
result = UnloadLib(backend_lib_handle_);
|
||||
if (Status::OK() != result) {
|
||||
LOGS_DEFAULT(ERROR) << "Failed to unload backend library: " << result.ErrorMessage();
|
||||
LOGS_DEFAULT(ERROR) << "Failed to unload backend library.";
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue