X-Git-Url: https://git.ozlabs.org/?a=blobdiff_plain;f=ccan%2Fhtable%2Ftools%2Fspeed.c;fp=ccan%2Fhtable%2Ftools%2Fspeed.c;h=4cbc5ead6552d560b9a0eb5d340420ed20dd4da7;hb=d9b63547c108a316a22c605503b100e58f2877ad;hp=a6e856d8c9a36f6300e7e7aa0f85245434408d4b;hpb=95ff2139520130dd98a0503e3c4f441c69a68f5a;p=ccan diff --git a/ccan/htable/tools/speed.c b/ccan/htable/tools/speed.c index a6e856d8..4cbc5ead 100644 --- a/ccan/htable/tools/speed.c +++ b/ccan/htable/tools/speed.c @@ -94,11 +94,11 @@ static size_t count_deleted(const struct htable *ht) } /* Nanoseconds per operation */ -static size_t normalize(const struct timespec *start, - const struct timespec *stop, +static size_t normalize(const struct timeabs *start, + const struct timeabs *stop, unsigned int num) { - return time_to_nsec(time_divide(time_sub(*stop, *start), num)); + return time_to_nsec(time_divide(time_between(*stop, *start), num)); } static size_t worst_run(struct htable *ht, size_t *deleted) @@ -128,7 +128,7 @@ int main(int argc, char *argv[]) { struct object *objs; size_t i, j, num, deleted; - struct timespec start, stop; + struct timeabs start, stop; struct htable_obj ht; bool make_dumb = false;