harness: improve _wait_for_clock_id_waits performance
authorHavard Graff <havard.graff@gmail.com>
Tue, 6 Nov 2018 10:45:45 +0000 (11:45 +0100)
committerHavard Graff <havard.graff@gmail.com>
Tue, 6 Nov 2018 10:46:06 +0000 (11:46 +0100)
commitfa347687299be0cdff35a9cf2d2fd196f37ccbb7
tree67fd493e5aa252b4cafcd5bccef755723fc04932
parentc6e5f59b2cc28addb24a885f0c92173129d94a38
harness: improve _wait_for_clock_id_waits performance

By moving the functionality down to the testclock, the implementation
no longer needs to poll the waits, but rather wait properly for
them to be added.

The performance-hit here would be that by polling the test-clock
regularly, you would create contention on the testclock-lock, making code
using the testclock (gst_clock_id_wait) fighting for the lock.
libs/gst/check/gstharness.c
libs/gst/check/gsttestclock.c
libs/gst/check/gsttestclock.h