On Mon, May 04, 2020 at 16:43:52 +0200, Philippe Mathieu-Daudé wrote:
> When building with Clang 10 on Fedora 32, we get:
> 
>   tests/qht-bench.c:287:29: error: implicit conversion from 'unsigned long' 
> to 'double' changes value from 18446744073709551615 to 18446744073709551616 
> [-Werror,-Wimplicit-int-float-conversion]
(snip)
> @@ -284,7 +285,7 @@ static void do_threshold(double rate, uint64_t *threshold)
>      if (rate == 1.0) {
>          *threshold = UINT64_MAX;
>      } else {
> -        *threshold = rate * UINT64_MAX;
> +        *threshold = rate * nextafter(0x1p64, 0.0);

Reviewed-by: Emilio G. Cota <c...@braap.org>

Please consider mentioning 25f74087c69 in the commit log -- it clearly
describes the problem.

Thanks,

                Emilio

Reply via email to