53 #ifndef ROCRAND_THREEFRY_COMMON_H_
54 #define ROCRAND_THREEFRY_COMMON_H_
57 #define FQUALIFIERS __forceinline__ __device__
60 #include "rocrand/rocrand_common.h"
63 #define SKEIN_MK_64(hi32, lo32) ((lo32) + (((unsigned long long)(hi32)) << 32))
64 #define SKEIN_KS_PARITY64 SKEIN_MK_64(0x1BD11BDA, 0xA9FC1A22)
65 #define SKEIN_KS_PARITY32 0x1BD11BDA
67 namespace rocrand_device
70 template<
typename value>
74 FQUALIFIERS unsigned long long rotl<unsigned long long>(
unsigned long long x,
int d)
76 return ((x << d) | (x >> (64 - d) & 63));
80 FQUALIFIERS unsigned int rotl<unsigned int>(
unsigned int x,
int d)
82 return (x << (d & 31)) | (x >> ((32 - d) & 31));
85 template<
typename value>
89 FQUALIFIERS unsigned int skein_ks_parity<unsigned int>()
91 return SKEIN_KS_PARITY32;
95 FQUALIFIERS unsigned long long skein_ks_parity<unsigned long long>()
97 return SKEIN_KS_PARITY64;
#define FQUALIFIERS
Shorthand for commonly used function qualifiers.
Definition: rocrand_uniform.h:31