Lines Matching refs:b

34                                                                type b,       \
39 if (!__builtin_add_overflow(a, b, &r)) \
47 type b, \
52 if (!__builtin_add_overflow(a, b, &r)) \
55 return a + b; \
61 type b, \
64 if ((a < 0) ^ (b < 0) \
65 || (a > 0 && b <= max - a) \
66 || (a < 0 && b >= min - a) \
68 return a + b; \
75 type b, \
78 if (b > max - a) \
80 return a + b; \
90 type b, \
95 if (!__builtin_sub_overflow(a, b, &r)) \
104 type b, \
107 if (!((a < 0) ^ (b < 0)) \
108 || (b > 0 && a >= min + b) \
109 || (b < 0 && a <= max + b) \
110 || b == 0) \
111 return a - b; \
120 type b, \
123 if (b > a) \
125 return a - b; \
134 type b, \
139 if (!__builtin_mul_overflow(a, b, &r)) \
142 return (a < 0) ^ (b < 0) ? min : max; \
147 type b, \
152 if (!__builtin_mul_overflow(a, b, &r)) \
155 return a * b; \
161 type b, \
164 if (a == 0 || b == 0) \
167 return b; \
168 if (b == 1) \
170 if (a != min && b != min) { \
172 const type y = b < 0 ? -b : b; \
175 return a * b; \
178 return (a < 0) ^ (b < 0) ? min : max; \
183 type b, \
186 if (b != 0 && a > max / b) \
188 return a * b; \
197 type b, \
200 if (b == 0) { \
204 if (b == -1 && a == min) { \
208 return a / b; \
213 type b, \
216 if (b != 0) \
217 return a / b; \
227 type b, \
230 if (b == 0) { \
234 if (b == -1 && a == min) { \
238 return a % b; \
243 type b, \
246 if (b != 0) \
247 return a % b; \
319 type b, \
328 return a == 0 || b == 0 ? 0 : max; \
330 x = safe_mul_ ## type_name(a, b, &e2); \
333 if (b > a) { \
334 x = b; \
335 b = a; \
340 x = safe_mul_ ## type_name(r, b, err); \
341 y = safe_mul_ ## type_name(q, b, err); \
348 type b, \
357 return a == 0 || b == 0 ? 0 : max; \
359 x = safe_mul_ ## type_name(a, b, &e2); \
362 if (b > a) { \
363 x = b; \
364 b = a; \
367 x = safe_mul_ ## type_name(a % c, b, err); \
368 y = safe_mul_ ## type_name(a / c, b, err); \
380 (type a, type b, int *errp) \
388 if (b > 0 && a > 0) { \
390 if (a < max - b) \
391 return (a + b - 1) / b; \
392 return a / b + (a % b != 0); \
394 if (b == 0) { \
401 x = safe_mod_ ## type_name(a, b, err); \
402 return safe_add_ ## type_name(safe_div_ ## type_name(a, b, err), \