|
|
@ -13,8 +13,9 @@ |
|
|
|
typedef uint u; |
|
|
|
typedef uint u; |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
#ifdef BFI_INT |
|
|
|
#ifdef BITALIGN |
|
|
|
#pragma OPENCL EXTENSION cl_amd_media_ops : enable |
|
|
|
#pragma OPENCL EXTENSION cl_amd_media_ops : enable |
|
|
|
|
|
|
|
#ifdef BFI_INT |
|
|
|
#define Ch(x, y, z) amd_bytealign(x, y, z) |
|
|
|
#define Ch(x, y, z) amd_bytealign(x, y, z) |
|
|
|
#define Ma(x, y, z) amd_bytealign(z ^ x, y, x) |
|
|
|
#define Ma(x, y, z) amd_bytealign(z ^ x, y, x) |
|
|
|
#else |
|
|
|
#else |
|
|
@ -27,6 +28,10 @@ |
|
|
|
#define Ma(z, x, y) Ch(z ^ x, y, x) |
|
|
|
#define Ma(z, x, y) Ch(z ^ x, y, x) |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
#else //BITALIGN |
|
|
|
|
|
|
|
#define Ch(x, y, z) (z ^ (x & (y ^ z))) |
|
|
|
|
|
|
|
#define Ma(x, y, z) ((x & z) | (y & (x | z))) |
|
|
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
#ifdef GOFFSET |
|
|
|
#ifdef GOFFSET |
|
|
|
// make sure kernel parameter "base" is not used, if GOFFSET is defined |
|
|
|
// make sure kernel parameter "base" is not used, if GOFFSET is defined |
|
|
|