[Mesa-dev] [PATCH] i965: fix comparison warning

Kenneth Graunke kenneth at whitecape.org
Mon Aug 1 04:25:00 UTC 2016


On Monday, August 1, 2016 10:35:06 AM PDT Timothy Arceri wrote:
> Cc: Kenneth Graunke <kenneth at whitecape.org>
> ---
>  src/mesa/drivers/dri/i965/brw_fs.cpp | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp
> index 3309f61..d1ac80a 100644
> --- a/src/mesa/drivers/dri/i965/brw_fs.cpp
> +++ b/src/mesa/drivers/dri/i965/brw_fs.cpp
> @@ -6381,7 +6381,7 @@ move_interpolation_to_top(nir_shader *nir)
>                 instr
>              };
>  
> -            for (int i = 0; i < ARRAY_SIZE(move); i++) {
> +            for (unsigned i = 0; i < ARRAY_SIZE(move); i++) {
>                 if (move[i]->block != top) {
>                    move[i]->block = top;
>                    exec_node_remove(&move[i]->node);
> 

Bah, thanks.  This used to be int i = 0; i < 3; i++ but I changed it to
ARRAY_SIZE in response review feedback, so now it should be unsigned...

Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part.
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160731/116d87be/attachment-0001.sig>


More information about the mesa-dev mailing list