From daf421e32981645e551621551c6b82697ad078de Mon Sep 17 00:00:00 2001 From: "Steinar H. Gunderson" Date: Thu, 12 Oct 2017 19:05:31 +0200 Subject: [PATCH] Silence some Mesa warnings. --- tally.shader | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tally.shader b/tally.shader index c83bfe4..a97a825 100644 --- a/tally.shader +++ b/tally.shader @@ -85,7 +85,7 @@ void main() barrier(); // Stick the thread ID in the lower mantissa bits so we never get a tie. - uint my_vote = (floatBitsToUint(loss) & ~0xff) | gl_LocalInvocationID.x; + uint my_vote = (floatBitsToUint(loss) & ~0xffu) | gl_LocalInvocationID.x; if (new_val <= 1) { // We can't touch this one any more, but it needs to participate in the barriers, // so we can't break. @@ -114,7 +114,7 @@ void main() for ( ; actual_sum != prob_scale; ++actual_sum, ++vote_no) { // Stick the thread ID in the lower mantissa bits so we never get a tie. - uint my_vote = (floatBitsToUint(benefit) & ~0xff) | gl_LocalInvocationID.x; + uint my_vote = (floatBitsToUint(benefit) & ~0xffu) | gl_LocalInvocationID.x; if (new_val == 0) { // It's meaningless to increase this, but it needs to participate in the barriers, // so we can't break. @@ -140,7 +140,7 @@ void main() } // Parallel prefix sum. - new_dist[(i + 255) & 255] = new_val; // Move the zero symbol last. + new_dist[(i + 255) & 255u] = new_val; // Move the zero symbol last. memoryBarrierShared(); barrier(); -- 2.39.2