From 2da7ec0db9d177bb37077d772145b9a7a82bc0eb Mon Sep 17 00:00:00 2001 From: Lionel Landwerlin Date: Sat, 15 Oct 2022 23:02:31 +0300 Subject: [PATCH] intel/clc: assert when libclc shader is not found Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/7483 Reviewed-by: Luis Felipe Strano Moraes Part-of: --- src/intel/compiler/brw_kernel.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/intel/compiler/brw_kernel.c b/src/intel/compiler/brw_kernel.c index 29ae5875d32..fd5f4e62180 100644 --- a/src/intel/compiler/brw_kernel.c +++ b/src/intel/compiler/brw_kernel.c @@ -299,6 +299,11 @@ brw_kernel_from_spirv(struct brw_compiler *compiler, spirv_options.clc_shader = load_clc_shader(compiler, disk_cache, nir_options, &spirv_options); + if (spirv_options.clc_shader == NULL) { + fprintf(stderr, "ERROR: libclc shader missing." + " Consider installing the libclc package\n"); + abort(); + } assert(spirv_size % 4 == 0); nir_shader *nir =