nir: fix loop iteration count calculation for floats
authorTimothy Arceri <timothy.arceri@collabora.com>
Tue, 3 Jan 2017 01:03:54 +0000 (12:03 +1100)
committerTimothy Arceri <timothy.arceri@collabora.com>
Wed, 4 Jan 2017 03:48:36 +0000 (14:48 +1100)
commit4b7dfd881296a542a0c08a12c27f643dabd7280c
treedeb00fa9d5298ca87310fd7ae789ed4903b66490
parentabcaba497d8c90a1e9dcede71261bdee16e2ed4e
nir: fix loop iteration count calculation for floats

Fixes performance regression in SynMark PSPom caused by loops with float
counters not always unrolling.

For example:

   for (float i = 0.02; i < 0.9; i += 0.11)
      ...

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
src/compiler/nir/nir_loop_analyze.c