Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test_loopback fails on Windows #567

Open
achronop opened this issue Jan 13, 2020 · 1 comment
Open

test_loopback fails on Windows #567

achronop opened this issue Jan 13, 2020 · 1 comment

Comments

@achronop
Copy link
Contributor

  1. test_loopback is failing with an assert:
Assertion failed: out_len == output_frame_count, file z:/build/build/src/media/libcubeb/src/cubeb_resampler_internal.h, line 257
  1. test_ring_buffer hangs
@kinetiknz
Copy link
Collaborator

test_ring_buffer appears hung, but it's just making progress extremely slowly. test_ring_multi is using std::this_thread::sleep_for to sleep for 10us, which I assume is intended to give the other test thread time to run. With Windows' default timer frequency, each sleep is probably taking ~15.6ms. Even calling timeBeginPeriod/timeEndPeriod doesn't help much; doing ~720000 ~1ms sleeps still takes a long time. On Linux we sleep ~34us and on macOS we get 10us.

Replacing sleep_for with yield, the test passes on my Windows 10 machine in ~2.5s. That change also drops the test duration from ~25s to ~1s on my Linux machine and ~7s to ~0.6s on macOS.

kinetiknz added a commit that referenced this issue Jan 21, 2020
padenot pushed a commit that referenced this issue Jan 21, 2020
@kinetiknz kinetiknz changed the title Windows test are broken test_loopback fails on Windows Jan 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants