Explicitly rename has_512 into has_avx512 (#7751)
This commit is contained in:
+1
-1
@@ -1077,7 +1077,7 @@ std::string jit_compiler::cpu(const std::string& _cpu)
|
||||
m_cpu == "tigerlake")
|
||||
{
|
||||
// Downgrade if AVX-512 is disabled or not supported
|
||||
if (!utils::has_512())
|
||||
if (!utils::has_avx512())
|
||||
{
|
||||
m_cpu = "skylake";
|
||||
}
|
||||
|
||||
@@ -56,10 +56,10 @@ bool utils::has_mpx()
|
||||
return g_value;
|
||||
}
|
||||
|
||||
bool utils::has_512()
|
||||
bool utils::has_avx512()
|
||||
{
|
||||
// Check AVX512F, AVX512CD, AVX512DQ, AVX512BW, AVX512VL extensions (Skylake-X level support)
|
||||
static const bool g_value = get_cpuid(0, 0)[0] >= 0x7 && (get_cpuid(7, 0)[1] & 0xd0030000) == 0xd0030000 && (get_cpuid(1,0)[2] & 0x0C000000) == 0x0C000000 && (get_xgetbv(0) & 0xe6) == 0xe6;
|
||||
static const bool g_value = get_cpuid(0, 0)[0] >= 0x7 && (get_cpuid(7, 0)[1] & 0xd0030000) == 0xd0030000 && (get_cpuid(1, 0)[2] & 0x0C000000) == 0x0C000000 && (get_xgetbv(0) & 0xe6) == 0xe6;
|
||||
return g_value;
|
||||
}
|
||||
|
||||
@@ -131,7 +131,7 @@ std::string utils::get_system_info()
|
||||
result += '+';
|
||||
}
|
||||
|
||||
if (has_512())
|
||||
if (has_avx512())
|
||||
{
|
||||
result += '+';
|
||||
}
|
||||
|
||||
+1
-1
@@ -41,7 +41,7 @@ namespace utils
|
||||
|
||||
bool has_mpx();
|
||||
|
||||
bool has_512();
|
||||
bool has_avx512();
|
||||
|
||||
bool has_xop();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user