Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ext/hash/hash_sha_ni.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@

# include <immintrin.h>

# if PHP_HASH_INTRIN_SHA_RESOLVER
# if defined(HAVE_FUNC_ATTRIBUTE_TARGET)
static __m128i be32dec_128(const uint8_t * src) __attribute__((target("ssse3")));
void SHA256_Transform_shani(uint32_t state[PHP_STATIC_RESTRICT 8], const uint8_t block[PHP_STATIC_RESTRICT 64]) __attribute__((target("ssse3,sha")));
# endif
Expand Down
4 changes: 2 additions & 2 deletions ext/hash/php_hash_sha.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,10 @@ PHP_HASH_API void PHP_SHA256Update(PHP_SHA256_CTX *, const unsigned char *, size
void SHA256_Transform_sse2(uint32_t state[PHP_STATIC_RESTRICT 8], const uint8_t block[PHP_STATIC_RESTRICT 64], uint32_t W[PHP_STATIC_RESTRICT 64], uint32_t S[PHP_STATIC_RESTRICT 8]);
#endif

#if (defined(__i386__) || defined(__x86_64__)) && defined(HAVE_IMMINTRIN_H)
#if ((defined(__i386__) || defined(__x86_64__)) && defined(HAVE_IMMINTRIN_H)) || defined(_M_X64) || defined(_M_IX86)
# if defined(__SSSE3__) && defined(__SHA__)
# define PHP_HASH_INTRIN_SHA_NATIVE 1
# elif defined(HAVE_FUNC_ATTRIBUTE_TARGET)
# elif defined(HAVE_FUNC_ATTRIBUTE_TARGET) || defined(_M_X64) || defined(_M_IX86)
# define PHP_HASH_INTRIN_SHA_RESOLVER 1
# endif
#endif
Expand Down
Loading