Mesa (main): microsoft/compiler: s/assert()/unreachable()/ in emit_intrinsic()

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Jun 14 23:17:13 UTC 2022


Module: Mesa
Branch: main
Commit: 65309dab45ad79ed1409471342680d3cccaba941
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=65309dab45ad79ed1409471342680d3cccaba941

Author: Boris Brezillon <boris.brezillon at collabora.com>
Date:   Fri Apr 22 14:56:17 2022 +0200

microsoft/compiler: s/assert()/unreachable()/ in emit_intrinsic()

Use an unreachable() statement instead of the incorrect assertion in the
unsupported intrinsic path.

Reviewed-by: Erik Faye-Lund <erik.faye-lund at collabora.com>
Reviewed-by: Jesse Natalie <jenatali at microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16926>

---

 src/microsoft/compiler/nir_to_dxil.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/microsoft/compiler/nir_to_dxil.c b/src/microsoft/compiler/nir_to_dxil.c
index bdca79bf9ec..ad3f962d4d9 100644
--- a/src/microsoft/compiler/nir_to_dxil.c
+++ b/src/microsoft/compiler/nir_to_dxil.c
@@ -4302,7 +4302,7 @@ emit_intrinsic(struct ntd_context *ctx, nir_intrinsic_instr *intr)
    case nir_intrinsic_load_workgroup_size:
    default:
       NIR_INSTR_UNSUPPORTED(&intr->instr);
-      assert("Unimplemented intrinsic instruction");
+      unreachable("Unimplemented intrinsic instruction");
       return false;
    }
 }



More information about the mesa-commit mailing list