Module: Mesa
Branch: staging/19.3
Commit: e65d8fce725224b78033babf8d98a2d24748d25b
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=e65d8fce725224b78033babf8d98a2d24748d25b

Author: Marek Olšák <[email protected]>
Date:   Wed Jan  8 21:52:26 2020 -0500

radeonsi: work around an LLVM crash when using llvm.amdgcn.icmp.i64.i1

Cc: 19.2 19.3 <[email protected]>
Acked-by: Pierre-Eric Pelloux-Prayer <[email protected]>
Tested-by: Marge Bot 
<https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3338>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3338>
(cherry picked from commit 8ff8e68e422a5c6b9ab26eaa56eff5c27a642d2e)

---

 .pick_status.json                                      | 2 +-
 src/gallium/drivers/radeonsi/si_compute_prim_discard.c | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/.pick_status.json b/.pick_status.json
index f91406b4fd1..6b97c9328cb 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -1453,7 +1453,7 @@
         "description": "radeonsi: work around an LLVM crash when using 
llvm.amdgcn.icmp.i64.i1",
         "nominated": true,
         "nomination_type": 0,
-        "resolution": 0,
+        "resolution": 1,
         "master_sha": null,
         "because_sha": null
     },
diff --git a/src/gallium/drivers/radeonsi/si_compute_prim_discard.c 
b/src/gallium/drivers/radeonsi/si_compute_prim_discard.c
index 34e6d344486..ecd32b0c81a 100644
--- a/src/gallium/drivers/radeonsi/si_compute_prim_discard.c
+++ b/src/gallium/drivers/radeonsi/si_compute_prim_discard.c
@@ -702,6 +702,7 @@ void si_build_prim_discard_compute_shader(struct 
si_shader_context *ctx)
                                 vp_scale, vp_translate, smallprim_precision,
                                 &options);
 
+       ac_build_optimization_barrier(&ctx->ac, &accepted);
        LLVMValueRef accepted_threadmask = ac_get_i1_sgpr_mask(&ctx->ac, 
accepted);
 
        /* Count the number of active threads by doing bitcount(accepted). */

_______________________________________________
mesa-commit mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to