Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
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
4 changes: 2 additions & 2 deletions src/ciphers/aes/aes_desc.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@
#define LTC_S_X86_CPUID
static LTC_INLINE void s_x86_cpuid(int* regs, int leaf)
{
#if defined _MSC_VER
#if defined(_MSC_VER) && !defined(__clang__) // MSVC but not ClangCL
__cpuid(regs, leaf);
#else
int a, b, c, d;

a = leaf;
b = c = d = 0;
asm volatile ("cpuid"
__asm__ volatile ("cpuid"
:"=a"(a), "=b"(b), "=c"(c), "=d"(d)
:"a"(a), "c"(c)
);
Expand Down
4 changes: 2 additions & 2 deletions src/encauth/gcm/gcm_gf_mult.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,14 @@
#define LTC_S_X86_CPUID
static LTC_INLINE void s_x86_cpuid(int* regs, int leaf)
{
#if defined _MSC_VER
#if defined(_MSC_VER) && !defined(__clang__) // MSVC but not ClangCL
__cpuid(regs, leaf);
#else
int a, b, c, d;

a = leaf;
b = c = d = 0;
asm volatile ("cpuid"
__asm__ volatile ("cpuid"
:"=a"(a), "=b"(b), "=c"(c), "=d"(d)
:"a"(a), "c"(c)
);
Expand Down
4 changes: 2 additions & 2 deletions src/hashes/sha1_desc.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,14 @@ const struct ltc_hash_descriptor sha1_desc =
#define LTC_S_X86_CPUID
static LTC_INLINE void s_x86_cpuid(int* regs, int leaf)
{
#if defined _MSC_VER
#if defined(_MSC_VER) && !defined(__clang__) // MSVC but not ClangCL
__cpuid(regs, leaf);
#else
int a, b, c, d;

a = leaf;
b = c = d = 0;
asm volatile ("cpuid"
__asm__ volatile ("cpuid"
:"=a"(a), "=b"(b), "=c"(c), "=d"(d)
:"a"(a), "c"(c)
);
Expand Down
4 changes: 2 additions & 2 deletions src/hashes/sha2/sha224_desc.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,14 @@ const struct ltc_hash_descriptor sha224_desc =
#define LTC_S_X86_CPUID
static LTC_INLINE void s_x86_cpuid(int* regs, int leaf)
{
#if defined _MSC_VER
#if defined(_MSC_VER) && !defined(__clang__) // MSVC but not ClangCL
__cpuid(regs, leaf);
#else
int a, b, c, d;

a = leaf;
b = c = d = 0;
asm volatile ("cpuid"
__asm__ volatile ("cpuid"
:"=a"(a), "=b"(b), "=c"(c), "=d"(d)
:"a"(a), "c"(c)
);
Expand Down
4 changes: 2 additions & 2 deletions src/hashes/sha2/sha256_desc.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@
#define LTC_S_X86_CPUID
static LTC_INLINE void s_x86_cpuid(int* regs, int leaf)
{
#if defined _MSC_VER
#if defined(_MSC_VER) && !defined(__clang__) // MSVC but not ClangCL
__cpuid(regs, leaf);
#else
int a, b, c, d;

a = leaf;
b = c = d = 0;
asm volatile ("cpuid"
__asm__ volatile ("cpuid"
:"=a"(a), "=b"(b), "=c"(c), "=d"(d)
:"a"(a), "c"(c)
);
Expand Down