test: lower number of tasks in threadpool test

Reduce the task count from 2*16*16 to 2*4*4 (512 vs. 32) because several
people have reported that the test frequently times out on their system.

Fixes: https://github.com/libuv/libuv/issues/1471
PR-URL: https://github.com/libuv/libuv/pull/1634
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
This commit is contained in:
Ben Noordhuis 2017-11-19 13:23:08 +01:00
parent 9594719e73
commit aeaff5f037

View File

@ -105,8 +105,8 @@ static void fs_cb(uv_fs_t* handle) {
static void do_work(void* arg) {
struct getaddrinfo_req getaddrinfo_reqs[16];
struct fs_req fs_reqs[16];
struct getaddrinfo_req getaddrinfo_reqs[4];
struct fs_req fs_reqs[4];
uv_loop_t loop;
size_t i;
struct test_thread* thread = arg;
@ -115,14 +115,14 @@ static void do_work(void* arg) {
for (i = 0; i < ARRAY_SIZE(getaddrinfo_reqs); i++) {
struct getaddrinfo_req* req = getaddrinfo_reqs + i;
req->counter = 16;
req->counter = 4;
req->loop = &loop;
getaddrinfo_do(req);
}
for (i = 0; i < ARRAY_SIZE(fs_reqs); i++) {
struct fs_req* req = fs_reqs + i;
req->counter = 16;
req->counter = 4;
req->loop = &loop;
fs_do(req);
}