[Mesa-dev] [PATCH] i965: Silence signed-unsigned int comparison warning by compiler

Anuj Phogat anuj.phogat at gmail.com
Tue Jul 28 16:45:02 PDT 2015


brw_cs.cpp:386:27: warning: comparison between signed and unsigned
integer expressions [-Wsign-compare]

Signed-off-by: Anuj Phogat <anuj.phogat at gmail.com>
---
 src/mesa/drivers/dri/i965/brw_cs.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/drivers/dri/i965/brw_cs.cpp b/src/mesa/drivers/dri/i965/brw_cs.cpp
index d61bba0..970d153 100644
--- a/src/mesa/drivers/dri/i965/brw_cs.cpp
+++ b/src/mesa/drivers/dri/i965/brw_cs.cpp
@@ -383,7 +383,7 @@ brw_upload_cs_state(struct brw_context *brw)
       brw->gen >= 8 ?
       SET_FIELD(threads, GEN8_MEDIA_GPGPU_THREAD_COUNT) :
       SET_FIELD(threads, MEDIA_GPGPU_THREAD_COUNT);
-   assert(threads <= brw->max_cs_threads);
+   assert(threads <= (unsigned) brw->max_cs_threads);
    desc[dw++] = media_threads;
 
    BEGIN_BATCH(4);
-- 
1.9.3



More information about the mesa-dev mailing list