Lines Matching refs:threads
171 struct test_thread threads[8];
175 memset(threads, 0, sizeof(threads));
177 for (i = 0; i < ARRAY_SIZE(threads); i++) {
178 r = uv_thread_create(&threads[i].thread_id, do_work, &threads[i]);
182 for (i = 0; i < ARRAY_SIZE(threads); i++) {
183 r = uv_thread_join(&threads[i].thread_id);
185 ASSERT_EQ(1, threads[i].thread_called);
203 uv_thread_t threads[2];
208 ASSERT_OK(uv_thread_create(threads + 0, tls_thread, threads + 0));
209 ASSERT_OK(uv_thread_create(threads + 1, tls_thread, threads + 1));
210 ASSERT_OK(uv_thread_join(threads + 0));
211 ASSERT_OK(uv_thread_join(threads + 1));
221 /* 512 kB is the default stack size of threads other than the main thread