Is there any way to improve the following Visual Studio 2019 C macros to make the final…
- User
Is there any way to improve the following Visual Studio 2019 C macros to make the final code run even faster? Here's the macros: #define ROTR64x4(x,s) ( _mm256_or_si256( _mm256_srli_epi64((x),s), _mm256_slli_epi64((x),64-s) ) )
#define Sigma0(x) ( _mm256_xor_si256(ROTR64x4(x,28), _mm256_xor_si256(ROTR64x4(x,34),ROTR64x4(x,39))) ) #define Sigma1(x) ( _mm256_xor_si256(ROTR64x4(x,14), _mm256_xor_si256(ROTR64x4(x,18),ROTR64x4(x,41))) ) #define sigma0(x) ( _mm256_xor_si256(ROTR64x4(x, 1), _mm256_xor_si256(ROTR64x4(x, 8),_mm256_srli_epi64(x,7))) ) #define sigma1(x) ( _mm256_xor_si256(ROTR64x4(x,19), _mm256_xor_si256(ROTR64x4(x,61),_mm256_srli_epi64(x,6))) )
#define Ch(x,y,z) (_mm256_xor_si256(_mm256_and_si256((x),(y)),_mm256_andnot_si256((x),(z)))) #define Maj(x,y,z) (_mm256_xor_si256(_mm256_and_si256((x),(y)),_mm256_and_si256(_mm256_xor_si256((x),(y)),(z)) ))
#define ROUND_00_15(i,a,b,c,d,e,f,g,h)
T1 = _mm256_add_epi64(T1, _mm256_add_epi64((h), _mm256_add_epi64(Sigma1((e)), _mm256_add_epi64(Ch((e),(f),(g)),K512[i]))));
h = _mm256_add_epi64(Sigma0((a)), Maj((a),(b),(c))); d = _mm256_add_epi64((d), T1); h = _mm256_add_epi64((h), T1);
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.