mirror of
https://github.com/matrix-construct/construct
synced 2024-09-27 19:28:52 +02:00
ircd::info: Add avx512f indicator; remove cruft; tweak info dump string.
This commit is contained in:
parent
52013c1ee0
commit
4184309ff2
2 changed files with 13 additions and 12 deletions
|
@ -117,9 +117,8 @@ namespace ircd::info::hardware::x86
|
||||||
extern const uint128_t _lwp;
|
extern const uint128_t _lwp;
|
||||||
|
|
||||||
extern const string_view vendor;
|
extern const string_view vendor;
|
||||||
extern const bool mmx, sse, sse2;
|
extern const bool sse, sse2, sse3, ssse3, sse4a, sse4_1, sse4_2;
|
||||||
extern const bool sse3, ssse3, sse4a, sse4_1, sse4_2;
|
extern const bool avx, avx2, avx512f;
|
||||||
extern const bool avx, avx2;
|
|
||||||
extern const bool tsc, tsc_constant;
|
extern const bool tsc, tsc_constant;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
20
ircd/info.cc
20
ircd/info.cc
|
@ -145,10 +145,11 @@ ircd::info::dump_cpu_info()
|
||||||
#if defined(__i386__) or defined(__x86_64__)
|
#if defined(__i386__) or defined(__x86_64__)
|
||||||
log::info
|
log::info
|
||||||
{
|
{
|
||||||
log::star, "%s sse:%b sse2:%b sse3:%b ssse3:%b sse4a:%b sse4.1:%b sse4.2:%b avx:%b avx2:%b constant_tsc:%b",
|
log::star, "%s %s sse3:%b ssse3:%b sse4a:%b sse4.1:%b sse4.2:%b avx:%b avx2:%b avx512f:%b constant_tsc:%b",
|
||||||
hardware::x86::vendor,
|
hardware::x86::vendor,
|
||||||
hardware::x86::sse,
|
hardware::virtualized?
|
||||||
hardware::x86::sse2,
|
"virtual"_sv:
|
||||||
|
"physical"_sv,
|
||||||
hardware::x86::sse3,
|
hardware::x86::sse3,
|
||||||
hardware::x86::ssse3,
|
hardware::x86::ssse3,
|
||||||
hardware::x86::sse4a,
|
hardware::x86::sse4a,
|
||||||
|
@ -156,6 +157,7 @@ ircd::info::dump_cpu_info()
|
||||||
hardware::x86::sse4_2,
|
hardware::x86::sse4_2,
|
||||||
hardware::x86::avx,
|
hardware::x86::avx,
|
||||||
hardware::x86::avx2,
|
hardware::x86::avx2,
|
||||||
|
hardware::x86::avx512f,
|
||||||
hardware::x86::tsc_constant,
|
hardware::x86::tsc_constant,
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
@ -378,12 +380,6 @@ ircd::info::hardware::x86::vendor{[]
|
||||||
};
|
};
|
||||||
}()};
|
}()};
|
||||||
|
|
||||||
decltype(ircd::info::hardware::x86::mmx)
|
|
||||||
ircd::info::hardware::x86::mmx
|
|
||||||
{
|
|
||||||
bool(features & (uint128_t(1) << (96 + 23)))
|
|
||||||
};
|
|
||||||
|
|
||||||
decltype(ircd::info::hardware::x86::sse)
|
decltype(ircd::info::hardware::x86::sse)
|
||||||
ircd::info::hardware::x86::sse
|
ircd::info::hardware::x86::sse
|
||||||
{
|
{
|
||||||
|
@ -438,6 +434,12 @@ ircd::info::hardware::x86::avx2
|
||||||
bool(features & (uint128_t(1) << (32 + 5)))
|
bool(features & (uint128_t(1) << (32 + 5)))
|
||||||
};
|
};
|
||||||
|
|
||||||
|
decltype(ircd::info::hardware::x86::avx512f)
|
||||||
|
ircd::info::hardware::x86::avx512f
|
||||||
|
{
|
||||||
|
bool(features & (uint128_t(1) << (32 + 16)))
|
||||||
|
};
|
||||||
|
|
||||||
decltype(ircd::info::hardware::x86::tsc)
|
decltype(ircd::info::hardware::x86::tsc)
|
||||||
ircd::info::hardware::x86::tsc
|
ircd::info::hardware::x86::tsc
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue