From f1bc58cb7bd7ee5622da2eec47921a5f8548b15c Mon Sep 17 00:00:00 2001 From: =?utf8?q?Iv=C3=A1n=20Briano?= Date: Tue, 12 Sep 2023 14:40:36 -0700 Subject: [PATCH] intel/fs: use ffsll so we don't explode on 32 bits Fixes: b200e5765cb ("anv: use a simpler MUE layout for fast linked libraries") Tested-by: Mark Janes Part-of: --- src/intel/compiler/brw_mesh.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/intel/compiler/brw_mesh.cpp b/src/intel/compiler/brw_mesh.cpp index 0c7eacd..b952784 100644 --- a/src/intel/compiler/brw_mesh.cpp +++ b/src/intel/compiler/brw_mesh.cpp @@ -918,7 +918,7 @@ brw_compute_mue_map(const struct brw_compiler *compiler, uint64_t per_prim_outputs = outputs_written & nir->info.per_primitive_outputs; while (per_prim_outputs) { - uint64_t location = ffsl(per_prim_outputs) - 1; + uint64_t location = ffsll(per_prim_outputs) - 1; assert(map->start_dw[location] == -1); assert(location == VARYING_SLOT_PRIMITIVE_ID || @@ -1040,7 +1040,7 @@ brw_compute_mue_map(const struct brw_compiler *compiler, uint64_t per_vertex_outputs = outputs_written & ~nir->info.per_primitive_outputs; while (per_vertex_outputs) { - uint64_t location = ffsl(per_vertex_outputs) - 1; + uint64_t location = ffsll(per_vertex_outputs) - 1; assert(map->start_dw[location] == -1); assert(location >= VARYING_SLOT_VAR0); -- 2.7.4