sha256_sse2.h 806 B

123456789101112131415161718192021222324
  1. #ifndef SHA256_SSE2_H_
  2. #define SHA256_SSE2_H_
  3. #include <stdint.h>
  4. /**
  5. * SHA256_Transform_sse2(state, block):
  6. * Compute the SHA256 block compression function, transforming ${state} using
  7. * the data in ${block}. This implementation uses x86 SSE2 instructions, and
  8. * should only be used if _SSE2 is defined and cpusupport_x86_sse2() returns
  9. * nonzero. The arrays W and S may be filled with sensitive data, and should
  10. * be cleared by the callee.
  11. */
  12. #ifdef POSIXFAIL_ABSTRACT_DECLARATOR
  13. void SHA256_Transform_sse2(uint32_t state[8],
  14. const uint8_t block[64], uint32_t W[64], uint32_t S[8]);
  15. #else
  16. void SHA256_Transform_sse2(uint32_t[static restrict 8],
  17. const uint8_t[static restrict 64], uint32_t W[static restrict 64],
  18. uint32_t S[static restrict 8]);
  19. #endif
  20. #endif /* !SHA256_SSE2_H_ */