diff --git a/src/main.cpp b/src/main.cpp index ab82cb2..13db00d 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -18,6 +18,10 @@ #include #endif +#include + +#include + #include #include #include @@ -59,7 +63,18 @@ int main(int argc, char** argv) { return EXIT_FAILURE; } - Utility::Debug{} << "===Initialising OpenGL renderer==="; + std::uint32_t brand[12]; + + if (!__get_cpuid_max(0x80000004, nullptr)) { + Utility::Warning{} << "Warning: CPUID features not supported. Can't get the current processor's model."; + } + else { + __get_cpuid(0x80000002, brand+0x0, brand+0x1, brand+0x2, brand+0x3); + __get_cpuid(0x80000003, brand+0x4, brand+0x5, brand+0x6, brand+0x7); + __get_cpuid(0x80000004, brand+0x8, brand+0x9, brand+0xa, brand+0xb); + Utility::Debug{} << "Processor:" << Containers::arrayCast(brand).data(); + } + SaveTool app({argc, argv}); Int result = app.exec();