Home
last modified time | relevance | path

Searched refs:promise (Results 1 – 25 of 132) sorted by relevance

123456

/aosp12/system/bt/gd/common/
H A Dbidi_queue_unittest.cc69 std::promise<void>* promise = new std::promise<void>(); in Send() local
74 common::Unretained(promise))); in Send()
75 return promise; in Send()
78 std::promise<TB*>* Receive() { in Receive()
79 std::promise<TB*>* promise = new std::promise<TB*>(); in Receive() local
83 return promise; in Receive()
86 void handle_send(TA* value, std::promise<void>* promise) { in handle_send() argument
96 std::unique_ptr<TA> handle_register_enqueue(TA* value, std::promise<void>* promise) { in handle_register_enqueue() argument
98 promise->set_value(); in handle_register_enqueue()
102 void handle_receive(std::promise<TB*>* promise) { in handle_receive() argument
[all …]
/aosp12/hardware/interfaces/biometrics/fingerprint/aidl/default/tests/
H A DWorkerThreadTest.cpp35 std::promise<void> promise; in TEST() local
36 auto future = promise.get_future(); in TEST()
38 ASSERT_TRUE(worker.schedule(Callable::from([promise = std::move(promise)]() mutable { in TEST()
40 promise.set_value(); in TEST()
50 std::promise<void> promise; in TEST() local
51 auto future = promise.get_future(); in TEST()
54 ASSERT_TRUE(worker.schedule(Callable::from([promise = std::move(promise)]() mutable { in TEST()
56 promise.set_value(); in TEST()
104 std::promise<void> promise1; in TEST()
105 std::promise<void> promise2; in TEST()
[all …]
/aosp12/system/bt/gd/
H A Dstack_manager.cc46 std::promise<void> promise; in StartUp() local
47 auto future = promise.get_future(); in StartUp()
49 std::move(promise))); in StartUp()
67 …ckManager::handle_start_up(ModuleList* modules, Thread* stack_thread, std::promise<void> promise) { in handle_start_up() argument
69 promise.set_value(); in handle_start_up()
75 std::promise<void> promise; in ShutDown() local
76 auto future = promise.get_future(); in ShutDown()
77 …t(common::BindOnce(&StackManager::handle_shut_down, common::Unretained(this), std::move(promise))); in ShutDown()
98 void StackManager::handle_shut_down(std::promise<void> promise) { in handle_shut_down() argument
100 promise.set_value(); in handle_shut_down()
/aosp12/system/bt/common/
H A Donce_timer.cc68 std::promise<void> promise; in Cancel() local
69 CancelHelper(std::move(promise)); in Cancel()
74 std::promise<void> promise; in CancelAndWait() local
75 auto future = promise.get_future(); in CancelAndWait()
76 CancelHelper(std::move(promise)); in CancelAndWait()
81 void OnceTimer::CancelHelper(std::promise<void> promise) { in CancelHelper() argument
85 promise.set_value(); in CancelHelper()
89 CancelClosure(std::move(promise)); in CancelHelper()
94 base::Unretained(this), std::move(promise))); in CancelHelper()
98 void OnceTimer::CancelClosure(std::promise<void> promise) { in CancelClosure() argument
[all …]
H A Drepeating_timer.cc78 std::promise<void> promise; in Cancel() local
79 CancelHelper(std::move(promise)); in Cancel()
84 std::promise<void> promise; in CancelAndWait() local
85 auto future = promise.get_future(); in CancelAndWait()
86 CancelHelper(std::move(promise)); in CancelAndWait()
91 void RepeatingTimer::CancelHelper(std::promise<void> promise) { in CancelHelper() argument
95 promise.set_value(); in CancelHelper()
99 CancelClosure(std::move(promise)); in CancelHelper()
104 base::Unretained(this), std::move(promise))); in CancelHelper()
108 void RepeatingTimer::CancelClosure(std::promise<void> promise) { in CancelClosure() argument
[all …]
H A Drepeating_timer_unittest.cc39 void IncreaseTaskCounter(int scheduled_tasks, std::promise<void>* promise) { in IncreaseTaskCounter() argument
42 promise->set_value(); in IncreaseTaskCounter()
46 void GetName(std::string* name, std::promise<void>* promise) { in GetName() argument
50 promise->set_value(); in GetName()
53 void SleepAndIncreaseCounter(std::promise<void>* promise, int sleep_ms) { in SleepAndIncreaseCounter() argument
54 promise->set_value(); in SleepAndIncreaseCounter()
62 std::promise<void>* promise) { in VerifyDelayTimeAndSleep() argument
69 promise->set_value(); in VerifyDelayTimeAndSleep()
101 promise_ = new std::promise<void>(); in SetUp()
117 std::promise<void>* promise_;
H A Donce_timer_unittest.cc39 void IncreaseTaskCounter(int scheduled_tasks, std::promise<void>* promise) { in IncreaseTaskCounter() argument
42 promise->set_value(); in IncreaseTaskCounter()
46 void GetName(std::string* name, std::promise<void>* promise) { in GetName() argument
50 promise->set_value(); in GetName()
53 void SleepAndIncreaseCounter(std::promise<void>* promise, int sleep_ms) { in SleepAndIncreaseCounter() argument
54 promise->set_value(); in SleepAndIncreaseCounter()
66 promise_ = new std::promise<void>(); in SetUp()
82 std::promise<void>* promise_;
/aosp12/system/bt/gd/os/linux_generic/
H A Drepeating_alarm_unittest.cc46 std::promise<void> promise; in VerifyMultipleDelayedTasks() local
47 auto future = promise.get_future(); in VerifyMultipleDelayedTasks()
57 common::Unretained(&promise), in VerifyMultipleDelayedTasks()
69 std::promise<void>* promise, in verify_delayed_tasks() argument
76 promise->set_value(); in verify_delayed_tasks()
96 std::promise<void> promise; in TEST_F() local
97 auto future = promise.get_future(); in TEST_F()
101 …common::Bind(&std::promise<void>::set_value, common::Unretained(&promise)), std::chrono::milliseco… in TEST_F()
123 std::promise<void> promise; in TEST_F() local
124 auto future = promise.get_future(); in TEST_F()
[all …]
H A Dqueue_unittest.cc78 std::promise<void> promise; in UnregisterEnqueue() local
124 void handle_unregister_enqueue(std::promise<void> promise) { in handle_unregister_enqueue() argument
126 promise.set_value(); in handle_unregister_enqueue()
143 std::promise<void> promise; in UnregisterDequeue() local
189 void handle_unregister_dequeue(std::promise<void> promise) { in handle_unregister_dequeue() argument
191 promise.set_value(); in handle_unregister_dequeue()
716 std::promise<void> promise; in TEST_F() local
720 [](os::Handler* dequeue_handler, Queue<std::string>* queue, std::promise<void>* promise) { in TEST_F() argument
722 [](Queue<std::string>* queue, std::promise<void>* promise) { in TEST_F() argument
876 std::promise<void> promise; in SynchronizeHandler() local
[all …]
H A Dalarm_unittest.cc56 std::promise<void> promise; in TEST_F() local
57 auto future = promise.get_future(); in TEST_F()
62 …BindOnce(&std::promise<void>::set_value, common::Unretained(&promise)), std::chrono::milliseconds(… in TEST_F()
82 std::promise<void> promise; in TEST_F() local
83 auto future = promise.get_future(); in TEST_F()
85 …BindOnce(&std::promise<void>::set_value, common::Unretained(&promise)), std::chrono::milliseconds(… in TEST_F()
H A Dhandler_unittest.cc54 std::promise<void> closure_ran; in TEST_F()
57 [](int* val, std::promise<void> closure_ran) { in TEST_F()
71 std::promise<void> closure_started; in TEST_F()
73 std::promise<void> closure_can_continue; in TEST_F()
76 [](int* val, std::promise<void> closure_started, std::future<void> can_continue_future) { in TEST_F()
105 std::promise<void> promise; in TEST_F() local
106 auto future = promise.get_future(); in TEST_F()
107 …auto once_callback = common::BindOnce(&std::promise<void>::set_value, common::Unretained(&promise)… in TEST_F()
/aosp12/system/bt/gd/l2cap/fuzz/
H A Dfuzz_dynamic_channel_manager_impl.h66 connected_promise_ = std::promise<void>(); in SetConnectionFuture()
75 register_promise_ = std::promise<void>(); in SetRegistrationFuture()
83 …nFail(l2cap::classic::DynamicChannelManager::ConnectionResult result, std::promise<void> promise) { in SetConnectionOnFail() argument
85 promise.set_value(); in SetConnectionOnFail()
88 …d SetConnectionOnOpen(std::unique_ptr<l2cap::DynamicChannel> channel, std::promise<void> promise) { in SetConnectionOnOpen() argument
90 promise.set_value(); in SetConnectionOnOpen()
101 std::promise<void> connected_promise_;
104 std::promise<void> register_promise_;
/aosp12/system/bt/gd/shim/
H A Ddumpsys.cc41 void DumpWithArgsSync(int fd, const char** args, std::promise<void> promise);
136 void Dumpsys::impl::DumpWithArgsSync(int fd, const char** args, std::promise<void> promise) { in DumpWithArgsSync() argument
138 promise.set_value(); in DumpWithArgsSync()
145 std::promise<void> promise; in Dump() local
146 auto future = promise.get_future(); in Dump()
147 CallOn(pimpl_.get(), &Dumpsys::impl::DumpWithArgsSync, fd, args, std::move(promise)); in Dump()
151 void Dumpsys::Dump(int fd, const char** args, std::promise<void> promise) { in Dump() argument
152 CallOn(pimpl_.get(), &Dumpsys::impl::DumpWithArgsSync, fd, args, std::move(promise)); in Dump()
H A Ddumpsys_test.cc111 std::promise<void> promise; in TEST_F() local
112 std::future future = promise.get_future(); in TEST_F()
113 dumpsys_module_->Dump(sv[0], args, std::move(promise)); in TEST_F()
128 std::promise<void> promise; in TEST_F() local
129 std::future future = promise.get_future(); in TEST_F()
130 dumpsys_module_->Dump(sv[0], args, std::move(promise)); in TEST_F()
/aosp12/frameworks/av/media/libstagefright/renderfright/threaded/
H A DRenderEngineThreaded.cpp87 std::promise<void> resultPromise; in primeCache()
119 std::promise<bool> resultPromise; in useNativeFenceSync()
134 std::promise<bool> resultPromise; in useWaitSync()
149 std::promise<void> resultPromise; in genTextures()
164 std::promise<void> resultPromise; in deleteTextures()
179 std::promise<void> resultPromise; in bindExternalTextureImage()
213 std::promise<void> resultPromise; in cacheExternalTextureBuffer()
228 std::promise<void> resultPromise; in unbindExternalTextureBuffer()
258 std::promise<void> resultPromise; in unbindFrameBuffer()
303 std::promise<bool> resultPromise; in isProtected()
[all …]
/aosp12/system/bt/gd/os/
H A Dqueue_benchmark.cc59 …EnqueueEnd(int64_t count, Queue<std::string>* queue, Handler* handler, std::promise<void>* promise) in TestEnqueueEnd() argument
60 : count_(count), handler_(handler), queue_(queue), promise_(promise) {} in TestEnqueueEnd()
99 std::promise<void>* promise_;
109 …DequeueEnd(int64_t count, Queue<std::string>* queue, Handler* handler, std::promise<void>* promise) in TestDequeueEnd() argument
110 : count_(count), handler_(handler), queue_(queue), promise_(promise) {} in TestDequeueEnd()
133 std::promise<void>* promise_;
146 std::promise<void> dequeue_promise; in BENCHMARK_DEFINE_F()
152 std::promise<void> enqueue_promise; in BENCHMARK_DEFINE_F()
180 std::promise<void> dequeue_promise; in BENCHMARK_DEFINE_F()
186 std::promise<void> enqueue_promise; in BENCHMARK_DEFINE_F()
/aosp12/system/bt/common/benchmark/
H A Dthread_performance_benchmark.cc70 set_up_promise_ = std::make_unique<std::promise<void>>(); in SetUp()
82 std::unique_ptr<std::promise<void>> set_up_promise_;
100 FROM_HERE, base::BindOnce(&std::promise<void>::set_value, in RunMessageLoop()
138 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
152 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
185 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
230 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
273 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
301 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
351 g_counter_promise = std::make_unique<std::promise<void>>(); in BENCHMARK_F()
[all …]
/aosp12/system/bt/gd/os/android/
H A Dwakelock_native_test.cc48 static std::unique_ptr<std::promise<void>> acquire_promise = nullptr;
49 static std::unique_ptr<std::promise<void>> release_promise = nullptr;
53 static void FulfilPromise(std::unique_ptr<std::promise<void>>& promise) { in FulfilPromise() argument
55 if (promise != nullptr) { in FulfilPromise()
56 promise->set_value(); in FulfilPromise()
57 promise = nullptr; in FulfilPromise()
61 …explicit PromiseFutureContext(std::unique_ptr<std::promise<void>>& promise, bool expect_fulfillmen… in PromiseFutureContext() argument
62 : promise_(promise), expect_fulfillment_(expect_fulfillment) { in PromiseFutureContext()
65 promise_ = std::make_unique<std::promise<void>>(); in PromiseFutureContext()
66 future_ = promise->get_future(); in PromiseFutureContext()
[all …]
/aosp12/hardware/interfaces/biometrics/fingerprint/2.1/vts/functional/
H A DVtsHalBiometricsFingerprintV2_1TargetTest.cpp128 promise.set_value(); in onEnumerate()
137 std::promise<void> promise; member in __anonf33b92db0110::EnumerateCallback
155 promise.set_value(); in onError()
165 std::promise<void> promise; member in __anonf33b92db0110::ErrorCallback
178 promise.set_value(); in onRemoved()
184 std::promise<void> promise; member in __anonf33b92db0110::RemoveCallback
261 ASSERT_TRUE(waitForCallback(cb->promise.get_future())); in TEST_P()
276 ASSERT_TRUE(waitForCallback(cb->promise.get_future())); in TEST_P()
305 ASSERT_TRUE(waitForCallback(cb->promise.get_future())); in TEST_P()
323 ASSERT_TRUE(waitForCallback(cb->promise.get_future())); in TEST_P()
[all …]
/aosp12/system/bt/test/headless/sdp/
H A Dsdp.cc34 auto promise = static_cast<std::promise<uint16_t>*>(user_data); in bta_jv_start_discovery_callback() local
35 promise->set_value(result); in bta_jv_start_discovery_callback()
93 std::promise<uint16_t> promise; in sdp_query_uuid() local
94 auto future = promise.get_future(); in sdp_query_uuid()
100 bta_jv_start_discovery_callback, (void*)&promise)) { in sdp_query_uuid()
/aosp12/system/bt/gd/l2cap/classic/
H A Dl2cap_classic_module.cc84 std::promise<flatbuffers::Offset<L2capClassicModuleData>> promise,
138 std::promise<flatbuffers::Offset<L2capClassicModuleData>> promise, in Dump() argument
152 promise.set_value(dumpsys_data); in Dump()
158 std::promise<flatbuffers::Offset<L2capClassicModuleData>> promise; in GetDumpsysData() local
159 auto future = promise.get_future(); in GetDumpsysData()
160 pimpl_->Dump(std::move(promise), fb_builder); in GetDumpsysData()
/aosp12/system/bt/gd/hci/
H A Dacl_manager.cc111 …std::promise<flatbuffers::Offset<AclManagerData>> promise, flatbuffers::FlatBufferBuilder* fb_buil…
135 void AclManager::UnregisterCallbacks(ConnectionCallbacks* callbacks, std::promise<void> promise) { in UnregisterCallbacks() argument
141 std::move(promise)); in UnregisterCallbacks()
153 void AclManager::UnregisterLeCallbacks(LeConnectionCallbacks* callbacks, std::promise<void> promise in UnregisterLeCallbacks() argument
155 …mpl_, &le_impl::handle_unregister_le_callbacks, common::Unretained(callbacks), std::move(promise)); in UnregisterLeCallbacks()
305 …std::promise<flatbuffers::Offset<AclManagerData>> promise, flatbuffers::FlatBufferBuilder* fb_buil… in Dump() argument
310 promise.set_value(dumpsys_data); in Dump()
316 std::promise<flatbuffers::Offset<AclManagerData>> promise; in GetDumpsysData() local
317 auto future = promise.get_future(); in GetDumpsysData()
318 pimpl_->Dump(std::move(promise), fb_builder); in GetDumpsysData()
/aosp12/system/bt/gd/l2cap/classic/internal/
H A Dsignalling_manager_test.cc39 std::promise<void> promise; in SyncHandler() local
40 auto future = promise.get_future(); in SyncHandler()
41 handler->Post(common::BindOnce(&std::promise<void>::set_value, common::Unretained(&promise))); in SyncHandler()
/aosp12/hardware/interfaces/contexthub/1.0/vts/functional/
H A DVtsHalContexthubV1_0TargetTest.cpp103 promise.set_value(appInfo); in handleAppsInfo()
107 std::promise<hidl_vec<HubAppInfo>> promise; member in __anone3df8d9e0110::QueryAppsCallback
121 ASSERT_TRUE(waitForCallback(cb->promise.get_future(), &appList)); in TEST_P()
137 promise.set_value(result); in handleTxnResult()
143 std::promise<TransactionResult> promise; member in __anone3df8d9e0110::TxnResultCallback
214 EXPECT_TRUE(checkFailureSyncOrAsync(result, Result::BAD_PARAMS, cb->promise.get_future())); in TEST_P()
222 EXPECT_TRUE(checkFailureSyncOrAsync(result, Result::BAD_PARAMS, cb->promise.get_future())); in TEST_P()
230 EXPECT_TRUE(checkFailureSyncOrAsync(result, Result::BAD_PARAMS, cb->promise.get_future())); in TEST_P()
238 EXPECT_TRUE(checkFailureSyncOrAsync(result, Result::BAD_PARAMS, cb->promise.get_future())); in TEST_P()
/aosp12/system/bt/common/test/
H A Dthread_performance_test.cc54 set_up_promise_ = std::make_unique<std::promise<void>>(); in SetUp()
65 std::unique_ptr<std::promise<void>> set_up_promise_ = nullptr;
83 FROM_HERE, base::Bind(&std::promise<void>::set_value, in RunMessageLoop()
120 g_counter_promise = std::make_unique<std::promise<void>>(); in TEST_F()
165 g_counter_promise = std::make_unique<std::promise<void>>(); in TEST_F()
210 g_counter_promise = std::make_unique<std::promise<void>>(); in TEST_F()
251 g_counter_promise = std::make_unique<std::promise<void>>(); in TEST_F()
284 FROM_HERE, base::Bind(&std::promise<void>::set_value, in SetUp()
301 g_counter_promise = std::make_unique<std::promise<void>>(); in TEST_F()
332 FROM_HERE, base::Bind(&std::promise<void>::set_value, in SetUp()
[all …]

123456