Add a thread yield to topic monitor torture test

This speeds up the test by about 5 msec.
This commit is contained in:
ridiculousfish 2021-02-08 14:06:47 -08:00
parent 4b9a096cf2
commit e423a58e24

View File

@ -6093,6 +6093,7 @@ static void test_topic_monitor_torture() {
while (completed.load(std::memory_order_relaxed) < thread_count) {
post_count += 1;
monitor.post(t1);
std::this_thread::yield();
}
for (auto &t : threads) t.join();
}