commit | 02d3a9485d1246ee3c12f38b235ab1c82987762f | [log] [tgz] |
---|---|---|
author | Michael Butler <butlermichael@google.com> | Thu Oct 14 22:09:21 2021 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Thu Oct 14 22:09:21 2021 +0000 |
tree | bdaff9c3e3ab4fe7d7ea6c8daa6f4423ca4cbf6b | |
parent | 0b0786abf0bebae9a343bfd72d4412d59dbaafc8 [diff] | |
parent | 608210f72c3482f8323832e22626fb1f4e7b3ca2 [diff] |
Merge "Handle error returned by IBurstContext::freeMemory" am: f3bd4751a3 am: 1b085b37c8 am: 608210f72c Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1856680 Change-Id: I326d84b15737e51ba1dc0cd040b16f6a7303cffd
diff --git a/neuralnetworks/1.2/utils/src/ExecutionBurstController.cpp b/neuralnetworks/1.2/utils/src/ExecutionBurstController.cpp index b4b6f68..8ce96c4 100644 --- a/neuralnetworks/1.2/utils/src/ExecutionBurstController.cpp +++ b/neuralnetworks/1.2/utils/src/ExecutionBurstController.cpp
@@ -176,7 +176,10 @@ std::lock_guard guard(mMutex); const int32_t slot = mMemoryIdToSlot.at(memory); if (mBurstContext) { - mBurstContext->freeMemory(slot); + const auto ret = mBurstContext->freeMemory(slot); + if (!ret.isOk()) { + LOG(ERROR) << "IBustContext::freeMemory failed: " << ret.description(); + } } mMemoryIdToSlot.erase(memory); mMemoryCache[slot] = {};