From c32c9014f5532829b5a24faaaa8f51947774d8ec Mon Sep 17 00:00:00 2001 From: "Thomas H.P. Andersen" Date: Sat, 25 Dec 2021 18:25:34 +0100 Subject: [PATCH] broadcom/compiler: fix compile warning -Wabsolute-value fixes a compile warning with clang Reviewed-by: Juan A. Suarez Part-of: --- src/broadcom/compiler/vir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/broadcom/compiler/vir.c b/src/broadcom/compiler/vir.c index eb2f380cb52..52e17857505 100644 --- a/src/broadcom/compiler/vir.c +++ b/src/broadcom/compiler/vir.c @@ -1201,7 +1201,7 @@ v3d_nir_sort_constant_ubo_load(nir_block *block, nir_intrinsic_instr *ref) * reference offset, since otherwise we would not be able to * skip the unifa write for them. See ntq_emit_load_ubo_unifa. */ - if (abs(ref_offset - offset) > MAX_UNIFA_SKIP_DISTANCE) + if (abs((int)(ref_offset - offset)) > MAX_UNIFA_SKIP_DISTANCE) continue; /* We will move this load if its offset is smaller than ref's