[Mesa-dev] [PATCH 2/2] i965: use a cast to silence a signed/unsigned comparison warning

Brian Paul brian.e.paul at gmail.com
Tue Oct 18 18:07:38 PDT 2011


From: Brian Paul <brianp at vmware.com>

---
 .../drivers/dri/i965/brw_vec4_reg_allocate.cpp     |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/brw_vec4_reg_allocate.cpp b/src/mesa/drivers/dri/i965/brw_vec4_reg_allocate.cpp
index 1ace91f..6de7682 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_reg_allocate.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_reg_allocate.cpp
@@ -217,7 +217,7 @@ vec4_visitor::reg_allocate()
       int reg = ra_get_node_reg(g, i);
 
       hw_reg_mapping[i] = first_assigned_grf + brw->vs.ra_reg_to_grf[reg];
-      prog_data->total_grf = MAX2(prog_data->total_grf,
+      prog_data->total_grf = MAX2((int) prog_data->total_grf,
 				  hw_reg_mapping[i] + virtual_grf_sizes[i]);
    }
 
-- 
1.7.3.4



More information about the mesa-dev mailing list