freedreno: Improve the pi approximations in trig lowering.
authorEric Anholt <eric@anholt.net>
Mon, 3 Jun 2019 23:12:14 +0000 (16:12 -0700)
committerEric Anholt <eric@anholt.net>
Tue, 4 Jun 2019 23:35:38 +0000 (23:35 +0000)
commitfb872748ec63f26213ca2021846c4c3a1c6ab1a8
treeadf61a62200243356f3a6ccf6e74ccbc094c23e3
parentff63b995310def60ac6a259f8d1c6e46d3c9a5a4
freedreno: Improve the pi approximations in trig lowering.

When comparing our sin/cos behavior to the closed source driver, I
noticed that we were off by a bit (or, in the case of 1/2pi, 3 bits).

Fixes:
dEQP-GLES3.functional.shaders.random.trigonometric.vertex.52
dEQP-GLES3.functional.shaders.random.all_features.vertex.0

Reviewed-by: Kristian H. Kristensen <hoegsberg@google.com>
Reviewed-by: Rob Clark <robdclark@gmail.com>
src/freedreno/ir3/ir3_nir_trig.py