summaryrefslogtreecommitdiff
path: root/nn/runtime/test/TestTrivialModel.cpp
diff options
context:
space:
mode:
authorMiao Wang <miaowang@google.com>2020-01-21 14:59:54 -0800
committerXusong Wang <xusongw@google.com>2020-01-30 15:25:17 -0800
commit16269ba3c8fdbd3f676c80c142b039dd4ce70646 (patch)
treed8b8ef335d48286eb1474c18928331ccdd52ea55 /nn/runtime/test/TestTrivialModel.cpp
parent86426ed77c242b5523a78b690d0e18b7593a903d (diff)
downloadml-16269ba3c8fdbd3f676c80c142b039dd4ce70646.tar.gz
Update sync fence related APIs
- Allow ANeuralNetworksExecution_startComputeWithDependencies to measure execution duration after all dependencies are done. - Allow ANeuralNetworksExecution_startComputeWithDependencies to specify post-gate-release timeout duration. Bug: 142778241 Bug: 136739795 Test: mm Test: NNAPI CTS & VTS tests Change-Id: Ie32e30b7d1cb98882f3084c1741e975d3e39d970 Merged-In: Ie32e30b7d1cb98882f3084c1741e975d3e39d970 (cherry picked from commit 879701620e997b462fdbd66bc5963dba47399436)
Diffstat (limited to 'nn/runtime/test/TestTrivialModel.cpp')
-rw-r--r--nn/runtime/test/TestTrivialModel.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/nn/runtime/test/TestTrivialModel.cpp b/nn/runtime/test/TestTrivialModel.cpp
index 557b2aa62..6bc2b2662 100644
--- a/nn/runtime/test/TestTrivialModel.cpp
+++ b/nn/runtime/test/TestTrivialModel.cpp
@@ -168,7 +168,7 @@ TEST_F(TrivialTest, FencedAddThree) {
ANeuralNetworksEvent* event1;
ANeuralNetworksExecution* execution1_handle = execution1.getHandle();
ASSERT_EQ(ANeuralNetworksExecution_startComputeWithDependencies(execution1_handle, nullptr, 0,
- &event1),
+ 0, &event1),
ANEURALNETWORKS_NO_ERROR);
// Start the second execution which will wait for the first one.
@@ -179,7 +179,7 @@ TEST_F(TrivialTest, FencedAddThree) {
ANeuralNetworksEvent* event2;
ANeuralNetworksExecution* execution2_handle = execution2.getHandle();
ASSERT_EQ(ANeuralNetworksExecution_startComputeWithDependencies(execution2_handle, &event1, 1,
- &event2),
+ 0, &event2),
ANEURALNETWORKS_NO_ERROR);
// Wait for the second event.
ASSERT_EQ(ANeuralNetworksEvent_wait(event2), ANEURALNETWORKS_NO_ERROR);