diff options
author | Axel Davy <[email protected]> | 2018-09-23 16:18:55 +0200 |
---|---|---|
committer | Axel Davy <[email protected]> | 2018-09-25 22:05:24 +0200 |
commit | 0d495bec25bd7584de4e988c2b4528c1996bc1d0 (patch) | |
tree | 4a01e51b99e0d7305d1523fd5bfddf90cfa6bbfd /src/gallium | |
parent | 46814e771a8eabc427e7d5bbaa8d5cb4ca57ee03 (diff) |
radeonsi: NaN should pass kill_if
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=105333
Fixes: https://github.com/iXit/Mesa-3D/issues/314
For this application, NaN is passed to KILL_IF and is expected to
pass.
v2: Explain in the code why UGE is used.
Signed-off-by: Axel Davy <[email protected]>
Reviewed-by: Marek Olšák <[email protected]>
CC: <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_shader_tgsi_alu.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gallium/drivers/radeonsi/si_shader_tgsi_alu.c b/src/gallium/drivers/radeonsi/si_shader_tgsi_alu.c index f54d025aec0..a768b449047 100644 --- a/src/gallium/drivers/radeonsi/si_shader_tgsi_alu.c +++ b/src/gallium/drivers/radeonsi/si_shader_tgsi_alu.c @@ -60,7 +60,8 @@ static void kil_emit(const struct lp_build_tgsi_action *action, for (i = 0; i < TGSI_NUM_CHANNELS; i++) { LLVMValueRef value = lp_build_emit_fetch(bld_base, inst, 0, i); - conds[i] = LLVMBuildFCmp(builder, LLVMRealOGE, value, + /* UGE because NaN shouldn't get killed */ + conds[i] = LLVMBuildFCmp(builder, LLVMRealUGE, value, ctx->ac.f32_0, ""); } |