Lines Matching +full:y +full:- +full:rc
2 * Copyright (C) 2017 - This file is part of libecc project
7 * Jean-Pierre FLORI <jean-pierre.flori@ssi.gouv.fr>
21 #define _KECCAK_ROTL_(x, y) (((x) << (y)) | ((x) >> ((sizeof(u64) * 8) - (y)))) argument
23 /* We handle the case where one of the shifts is more than 64-bit: in this
27 #define KECCAK_ROTL(x, y) ((((y) < (sizeof(u64) * 8)) && ((y) > 0)) ? (_KECCAK_ROTL_(x, y)) : (x)) argument
65 #define SWAP64_Idx(a) ((sizeof(u64) * ((u8)(a) / sizeof(u64))) + (sizeof(u64) - 1 - ((u8)(a) % si…
67 #define Idx_slices(x, y) ((x) + (KECCAK_SLICES * (y))) argument
68 #define Idx(A, x, y) ((A)[Idx_slices(x, y)]) argument
70 #define KECCAKROUND(A, RC) do { \ argument
71 int x, y; \
83 for(y = 0; y < KECCAK_SLICES; y++){ \
84 Idx(A, x, y) ^= tmp; \
89 for(y = 0; y < KECCAK_SLICES; y++){ \
90 Idx(BCD, y, ((2*x)+(3*y)) % 5) = \
91 KECCAK_ROTL(Idx(A, x, y), keccak_rot[x][y]); \
96 for(y = 0; y < KECCAK_SLICES; y++){ \
97 Idx(A, x, y) = Idx(BCD, x, y) ^ \
98 (~Idx(BCD, (x+1) % 5, y) & Idx(BCD, (x+2)%5, y)); \
102 Idx(A, 0, 0) ^= (RC); \