ac: fix nir_op_fdd{x,y} handling
authorTimothy Arceri <tarceri@itsqueeze.com>
Tue, 27 Feb 2018 05:08:40 +0000 (16:08 +1100)
committerTimothy Arceri <tarceri@itsqueeze.com>
Tue, 27 Feb 2018 22:23:49 +0000 (09:23 +1100)
commit9790921ff5c88ad860c55ba21ef1d66afd9ab2dc
treef1f52aa93837a7ce3abb973a7ce5e7559a5e20df
parent8de6f7970702ec69143c4e256bbeab64fe7d79c0
ac: fix nir_op_fdd{x,y} handling

radeonsi, i965 and anv all treat fdd{x,y} opcodes the same as
fdd{x,y}_coarse by default. The SPIR-V spec lets the implementation
decide how it should be handled and radv was previously going
for the higher quality option. Here we change the shared amd
code to match how nir_op_fdd{x,y} is expected to be handled
by the other NIR drivers.

Fixes piglit test:
./bin/arb_shader_texture_lod-texgrad -auto

Reviewed-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/amd/common/ac_nir_to_llvm.c