diff options
Diffstat (limited to 'unittest')
-rw-r--r-- | unittest/mysys/thr_template.c | 6 | ||||
-rw-r--r-- | unittest/mysys/waiting_threads-t.c | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/unittest/mysys/thr_template.c b/unittest/mysys/thr_template.c index e6af1fb12e2..5fc0d1497bf 100644 --- a/unittest/mysys/thr_template.c +++ b/unittest/mysys/thr_template.c @@ -29,7 +29,7 @@ void do_tests(); void test_concurrently(const char *test, pthread_handler handler, int n, int m) { pthread_t t; - ulonglong now= my_getsystime(); + ulonglong now= my_interval_timer(); bad= 0; @@ -47,8 +47,8 @@ void test_concurrently(const char *test, pthread_handler handler, int n, int m) pthread_cond_wait(&cond, &mutex); pthread_mutex_unlock(&mutex); - now= my_getsystime()-now; - ok(!bad, "tested %s in %g secs (%d)", test, ((double)now)/1e7, bad); + now= my_interval_timer() - now; + ok(!bad, "tested %s in %g secs (%d)", test, ((double)now)/1e9, bad); } int main(int argc __attribute__((unused)), char **argv) diff --git a/unittest/mysys/waiting_threads-t.c b/unittest/mysys/waiting_threads-t.c index 7bb5b2038fb..35e86aca319 100644 --- a/unittest/mysys/waiting_threads-t.c +++ b/unittest/mysys/waiting_threads-t.c @@ -65,7 +65,7 @@ pthread_handler_t test_wt(void *arg) my_rnd_init(&rand, (ulong)(intptr)&m, id); if (kill_strategy == YOUNGEST) - thds[id].thd.weight= (ulong)~my_getsystime(); + thds[id].thd.weight= (ulong) ~ my_interval_timer(); if (kill_strategy == LOCKS) thds[id].thd.weight= 0; @@ -116,7 +116,7 @@ retry: if (kill_strategy == LOCKS) thds[id].thd.weight= 0; if (kill_strategy == YOUNGEST) - thds[id].thd.weight= (ulong)~my_getsystime(); + thds[id].thd.weight= (ulong)~ my_interval_timer(); } else if (kill_strategy == LOCKS) thds[id].thd.weight++; |