We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents e93bd2e + e821164 commit 9b6039eCopy full SHA for 9b6039e
src/strategies/radixk.c
@@ -132,8 +132,11 @@ static IceTInt* radixkGetK(IceTInt world_size, IceTInt* num_rounds_p)
132
133
/* If that does not work, look for a factor near the magic_k. */
134
if (next_k == -1) {
135
- IceTInt try_k;
136
- BEGIN_PIVOT_FOR(try_k, 2, magic_k, 2*magic_k) {
+ /* All these unsigned ints just get around a compiler warning
+ about a compiler optimization that assumes no signed overflow.
137
+ Yes, I am aware that all numbers will be positive. */
138
+ IceTUInt try_k;
139
+ BEGIN_PIVOT_FOR(try_k, 2, (IceTUInt)magic_k, 2*(IceTUInt)magic_k) {
140
if ((next_divide % try_k) == 0) {
141
next_k = try_k;
142
break;
0 commit comments