Cipher Fayadh
Block cipher Feistel 128-bit dengan fungsi putaran sigma-delta
Loading...
Searching...
No Matches
bits.hpp
Go to the documentation of this file.
1#ifndef BITS_HPP
2#define BITS_HPP
3
4#include <cstdint>
5
10
21inline uint64_t rotl64(uint64_t x, unsigned n){
22 return (x << n) | x >> (64 - n);
23}
24
25
36inline uint32_t rotl32(uint32_t x, unsigned n){
37 return (x << n) | x >> (32 - n);
38}
39
40#endif
uint32_t rotl32(uint32_t x, unsigned n)
Rotasi kiri 32 bit.
Definition bits.hpp:36
uint64_t rotl64(uint64_t x, unsigned n)
Rotasi kiri 64 bit.
Definition bits.hpp:21