# HG changeset patch # User Mike Becker # Date 1526315015 -7200 # Node ID b7753273f0fd23cb011b46c3c2b42a5d66e5fc7d # Parent e1e3b768ae8be8ec001c9546ca47e0c90735a146 renames ucx_doublecmp() and ucx_floatcmp() to ucx_cmp_double() and ucx_cmp_float() diff -r e1e3b768ae8b -r b7753273f0fd src/ucx/utils.h --- a/src/ucx/utils.h Mon May 14 18:20:56 2018 +0200 +++ b/src/ucx/utils.h Mon May 14 18:23:35 2018 +0200 @@ -212,7 +212,7 @@ * 1 if *f1 is greater than *f2 */ -int ucx_floatcmp(const void *f1, const void *f2, void *data); +int ucx_cmp_float(const void *f1, const void *f2, void *data); /** * Compares two real numbers of type double. @@ -222,7 +222,7 @@ * @return -1, if *d1 is less than *d2, 0 if both are equal, * 1 if *d1 is greater than *d2 */ -int ucx_doublecmp(const void *d1, const void *d2, void *data); +int ucx_cmp_double(const void *d1, const void *d2, void *data); /** * Compares two pointers. diff -r e1e3b768ae8b -r b7753273f0fd src/utils.c --- a/src/utils.c Mon May 14 18:20:56 2018 +0200 +++ b/src/utils.c Mon May 14 18:23:35 2018 +0200 @@ -134,7 +134,7 @@ return a - b; } -int ucx_floatcmp(const void *f1, const void *f2, void *epsilon) { +int ucx_cmp_float(const void *f1, const void *f2, void *epsilon) { float a = *((const float*) f1); float b = *((const float*) f2); float e = !epsilon ? 1e-6f : *((float*)epsilon); @@ -145,7 +145,7 @@ } } -int ucx_doublecmp(const void *d1, const void *d2, void *epsilon) { +int ucx_cmp_double(const void *d1, const void *d2, void *epsilon) { double a = *((const double*) d1); double b = *((const double*) d2); double e = !epsilon ? 1e-14 : *((double*)epsilon);