Lines Matching +full:128 +full:a
24 static void s390_vec_and(S390Vector *res, const S390Vector *a, in s390_vec_and() argument
27 res->doubleword[0] = a->doubleword[0] & b->doubleword[0]; in s390_vec_and()
28 res->doubleword[1] = a->doubleword[1] & b->doubleword[1]; in s390_vec_and()
31 static bool s390_vec_equal(const S390Vector *a, const S390Vector *b) in s390_vec_equal() argument
33 return a->doubleword[0] == b->doubleword[0] && in s390_vec_equal()
34 a->doubleword[1] == b->doubleword[1]; in s390_vec_equal()
37 static void s390_vec_shl(S390Vector *d, const S390Vector *a, uint64_t count) in s390_vec_shl() argument
41 g_assert(count < 128); in s390_vec_shl()
43 d->doubleword[0] = a->doubleword[0]; in s390_vec_shl()
44 d->doubleword[1] = a->doubleword[1]; in s390_vec_shl()
46 d->doubleword[0] = a->doubleword[1]; in s390_vec_shl()
49 tmp = extract64(a->doubleword[1], 64 - count, count); in s390_vec_shl()
50 d->doubleword[1] = a->doubleword[1] << count; in s390_vec_shl()
51 d->doubleword[0] = (a->doubleword[0] << count) | tmp; in s390_vec_shl()
53 d->doubleword[0] = a->doubleword[1] << (count - 64); in s390_vec_shl()
58 static void s390_vec_sar(S390Vector *d, const S390Vector *a, uint64_t count) in s390_vec_sar() argument
63 d->doubleword[0] = a->doubleword[0]; in s390_vec_sar()
64 d->doubleword[1] = a->doubleword[1]; in s390_vec_sar()
66 tmp = (int64_t)a->doubleword[0] >> 63; in s390_vec_sar()
67 d->doubleword[1] = a->doubleword[0]; in s390_vec_sar()
70 tmp = a->doubleword[1] >> count; in s390_vec_sar()
71 d->doubleword[1] = deposit64(tmp, 64 - count, count, a->doubleword[0]); in s390_vec_sar()
72 d->doubleword[0] = (int64_t)a->doubleword[0] >> count; in s390_vec_sar()
74 tmp = (int64_t)a->doubleword[0] >> 63; in s390_vec_sar()
75 d->doubleword[1] = (int64_t)a->doubleword[0] >> (count - 64); in s390_vec_sar()
80 static void s390_vec_shr(S390Vector *d, const S390Vector *a, uint64_t count) in s390_vec_shr() argument
84 g_assert(count < 128); in s390_vec_shr()
86 d->doubleword[0] = a->doubleword[0]; in s390_vec_shr()
87 d->doubleword[1] = a->doubleword[1]; in s390_vec_shr()
89 d->doubleword[1] = a->doubleword[0]; in s390_vec_shr()
92 tmp = a->doubleword[1] >> count; in s390_vec_shr()
93 d->doubleword[1] = deposit64(tmp, 64 - count, count, a->doubleword[0]); in s390_vec_shr()
94 d->doubleword[0] = a->doubleword[0] >> count; in s390_vec_shr()
96 d->doubleword[1] = a->doubleword[0] >> (count - 64); in s390_vec_shr()
106 for (i = 0; i < (128 / BITS); i++) { \
107 const int32_t a = (int##BITS##_t)s390_vec_read_element##BITS(v2, i); \
110 s390_vec_write_element##BITS(v1, i, (a + b + 1) >> 1); \
122 for (i = 0; i < (128 / BITS); i++) { \
123 const uint##BITS##_t a = s390_vec_read_element##BITS(v2, i); \
126 s390_vec_write_element##BITS(v1, i, (a + b + 1) >> 1); \
137 for (i = 0; i < (128 / BITS); i++) { \
138 const uint##BITS##_t a = s390_vec_read_element##BITS(v2, i); \
140 s390_vec_write_element##BITS(v1, i, clz32(a) - 32 + BITS); \
151 for (i = 0; i < (128 / BITS); i++) { \
152 const uint##BITS##_t a = s390_vec_read_element##BITS(v2, i); \
154 s390_vec_write_element##BITS(v1, i, a ? ctz32(a) : BITS); \
166 static inline uint64_t do_gfma8(uint64_t n, uint64_t m, uint64_t a) in do_gfma8() argument
168 return clmul_8x4_even(n, m) ^ clmul_8x4_odd(n, m) ^ a; in do_gfma8()
190 static inline uint64_t do_gfma16(uint64_t n, uint64_t m, uint64_t a) in do_gfma16() argument
192 return clmul_16x2_even(n, m) ^ clmul_16x2_odd(n, m) ^ a; in do_gfma16()
214 static inline uint64_t do_gfma32(uint64_t n, uint64_t m, uint64_t a) in do_gfma32() argument
216 return clmul_32(n, m) ^ clmul_32(n >> 32, m >> 32) ^ a; in do_gfma32()
268 for (i = 0; i < (128 / BITS); i++) { \
269 const uint##BITS##_t a = s390_vec_read_element##BITS(v2, i); \
273 s390_vec_write_element##BITS(v1, i, a * b + c); \
285 for (i = 0; i < (128 / BITS); i++) { \
286 const int32_t a = (int##BITS##_t)s390_vec_read_element##BITS(v2, i); \
290 s390_vec_write_element##BITS(v1, i, (a * b + c) >> BITS); \
302 for (i = 0; i < (128 / BITS); i++) { \
303 const uint##BITS##_t a = s390_vec_read_element##BITS(v2, i); \
307 s390_vec_write_element##BITS(v1, i, (a * b + c) >> BITS); \
319 for (i = 0, j = 0; i < (128 / TBITS); i++, j += 2) { \
320 int##TBITS##_t a = (int##BITS##_t)s390_vec_read_element##BITS(v2, j); \
324 s390_vec_write_element##TBITS(v1, i, a * b + c); \
337 for (i = 0, j = 0; i < (128 / TBITS); i++, j += 2) { \
338 uint##TBITS##_t a = s390_vec_read_element##BITS(v2, j); \
342 s390_vec_write_element##TBITS(v1, i, a * b + c); \
355 for (i = 0, j = 1; i < (128 / TBITS); i++, j += 2) { \
356 int##TBITS##_t a = (int##BITS##_t)s390_vec_read_element##BITS(v2, j); \
360 s390_vec_write_element##TBITS(v1, i, a * b + c); \
373 for (i = 0, j = 1; i < (128 / TBITS); i++, j += 2) { \
374 uint##TBITS##_t a = s390_vec_read_element##BITS(v2, j); \
378 s390_vec_write_element##TBITS(v1, i, a * b + c); \
391 for (i = 0; i < (128 / BITS); i++) { \
392 const int32_t a = (int##BITS##_t)s390_vec_read_element##BITS(v2, i); \
395 s390_vec_write_element##BITS(v1, i, (a * b) >> BITS); \
407 for (i = 0; i < (128 / BITS); i++) { \
408 const uint##BITS##_t a = s390_vec_read_element##BITS(v2, i); \
411 s390_vec_write_element##BITS(v1, i, (a * b) >> BITS); \
423 for (i = 0, j = 0; i < (128 / TBITS); i++, j += 2) { \
424 int##TBITS##_t a = (int##BITS##_t)s390_vec_read_element##BITS(v2, j); \
427 s390_vec_write_element##TBITS(v1, i, a * b); \
440 for (i = 0, j = 0; i < (128 / TBITS); i++, j += 2) { \
441 const uint##TBITS##_t a = s390_vec_read_element##BITS(v2, j); \
444 s390_vec_write_element##TBITS(v1, i, a * b); \
457 for (i = 0, j = 1; i < (128 / TBITS); i++, j += 2) { \
458 int##TBITS##_t a = (int##BITS##_t)s390_vec_read_element##BITS(v2, j); \
461 s390_vec_write_element##TBITS(v1, i, a * b); \
474 for (i = 0, j = 1; i < (128 / TBITS); i++, j += 2) { \
475 const uint##TBITS##_t a = s390_vec_read_element##BITS(v2, j); \
478 s390_vec_write_element##TBITS(v1, i, a * b); \
490 for (i = 0; i < (128 / BITS); i++) { \
491 const uint##BITS##_t a = s390_vec_read_element##BITS(v2, i); \
493 s390_vec_write_element##BITS(v1, i, ctpop32(a)); \
506 for (i = 0; i < (128 / BITS); i++) { \
507 const uint##BITS##_t a = s390_vec_read_element##BITS(v1, i); \
510 const uint##BITS##_t d = (a & ~mask) | (rol##BITS(b, count) & mask); \
597 for (i = 0; i < (128 / BITS); i++) { \
598 const uint##BITS##_t a = s390_vec_read_element##BITS(v2, i); \
601 s390_vec_write_element##BITS(v1, i, a >= b); \
620 /* Selected bits a mix of zeros and ones */ in HELPER()