[2/2] radv: do not lower float comparisons because they have to be exact

Submitted by Samuel Pitoiset on Nov. 29, 2018, 3:20 p.m.

Details

Message ID 20181129152011.16127-2-samuel.pitoiset@gmail.com
State New
Headers show
Series "Series without cover letter" ( rev: 1 ) in Mesa

Not browsing as part of any series.

Commit Message

Samuel Pitoiset Nov. 29, 2018, 3:20 p.m.
This fixes two test failures in the VKD3D testsuite.
(ie. in test_shader_instructions().

26260 shaders in 13493 tests
Totals:
SGPRS: 1203796 -> 1203948 (0.01 %)
VGPRS: 844968 -> 845052 (0.01 %)
Spilled SGPRs: 21844 -> 21821 (-0.11 %)
Spilled VGPRs: 122 -> 122 (0.00 %)
Code Size: 44707992 -> 44635672 (-0.16 %) bytes
Max Waves: 219539 -> 219529 (-0.00 %)

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
---
 src/amd/vulkan/radv_shader.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/src/amd/vulkan/radv_shader.c b/src/amd/vulkan/radv_shader.c
index 456c462a230..870105fa85c 100644
--- a/src/amd/vulkan/radv_shader.c
+++ b/src/amd/vulkan/radv_shader.c
@@ -71,7 +71,8 @@  static const struct nir_shader_compiler_options nir_options = {
 	.lower_extract_word = true,
 	.lower_ffma = true,
 	.lower_fpow = true,
-	.max_unroll_iterations = 32
+	.max_unroll_iterations = 32,
+	.exact_float_comparisons = true,
 };
 
 VkResult radv_CreateShaderModule(