Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 3da128d7 authored by Robert Wu's avatar Robert Wu
Browse files

AAudio: Use futex for waitForStateChange

WaitForStateChange currently waits in twenty millisecond intervals
for state changes. This is clearly inefficient and if apps use this
consistently, much extra latency is added. This CL adds futexes so
the callback fires almost immediately after a state change.

This CL also changes updateStateMachine so updates from non-callbacks
do not happen if a callback thread is running.

Bug: 70722092
Test: atest AAudioTests
Test: Oboe automated tests (./run_tests.sh)
Test: OboeTester Plug Latency Test
Change-Id: I186dc9ddac7f3897d82a5ed0043a5f45f1c19fe3
parent 059aa2d7
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment