Skip to content

Commit

Permalink
Use _py prefix
Browse files Browse the repository at this point in the history
  • Loading branch information
picnixz authored Oct 5, 2024
1 parent f4e4f99 commit 5006686
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions Include/internal/pycore_cpuinfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ extern "C" {
typedef struct {
bool sse, sse2, sse3, sse41, sse42, avx, avx2, avx512vbmi;
bool done;
} cpu_simd_flags;
} _py_cpu_simd_flags;

extern void
_Py_detect_cpu_simd_features(cpu_simd_flags *flags);
_Py_detect_cpu_simd_features(_py_cpu_simd_flags *flags);

#ifdef __cplusplus
}
Expand Down
6 changes: 3 additions & 3 deletions Python/cpuinfo.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
#include <stdbool.h>

#if defined(__x86_64__) && defined(__GNUC__)
#include <cpuid.h>
# include <cpuid.h>
#elif defined(_M_X64)
#include <intrin.h>
# include <intrin.h>
#endif

// AVX2 cannot be compiled on macOS ARM64 (yet it can be compiled on x86_64).
Expand All @@ -34,7 +34,7 @@
#define ECX7_AVX512_VBMI (1 << 1) // avx512-vbmi, ECX, page 7, bit 1

void
_Py_detect_cpu_simd_features(cpu_simd_flags *flags)
_Py_detect_cpu_simd_features(_py_cpu_simd_flags *flags)
{
if (flags->done) {
return;
Expand Down

0 comments on commit 5006686

Please sign in to comment.