| 33 | uint32_t inline rol(uint32_t x, int i) { return (x << i) | (x >> (32 - i)); } |
| 34 | |
| 35 | void inline Round(uint32_t& a, uint32_t b, uint32_t& c, uint32_t d, uint32_t e, uint32_t f, uint32_t x, uint32_t k, int r) |
| 36 | { |
| 37 | a = rol(a + f + x + k, r) + e; |
| 38 | c = rol(c, 10); |
| 39 | } |
| 40 | |
| 41 | void inline R11(uint32_t& a, uint32_t b, uint32_t& c, uint32_t d, uint32_t e, uint32_t x, int r) { Round(a, b, c, d, e, f1(b, c, d), x, 0, r); } |
| 42 | void inline R21(uint32_t& a, uint32_t b, uint32_t& c, uint32_t d, uint32_t e, uint32_t x, int r) { Round(a, b, c, d, e, f2(b, c, d), x, 0x5A827999ul, r); } |