26 lines
557 B
C
Raw Normal View History

2020-09-20 05:02:35 +08:00
#ifndef HGL_PLATFORM_CPU_INFO_INCLUDE
2020-08-19 11:44:25 +08:00
#define HGL_PLATFORM_CPU_INFO_INCLUDE
#include<hgl/type/DataType.h>
namespace hgl
{
enum class CpuArch
{
x86_64,
ARMv8,
};//
struct CpuInfo
{
uint cpu_count; ///<处理器数量
uint core_count; ///<处理器核心数量
uint logical_core_count; ///<逻辑处理器核心数量
};//struct CpuInfo
/**
* CPU信息
*/
bool GetCpuInfo(CpuInfo *);
}//namespace hgl
#endif//HGL_PLATFORM_CPU_INFO_INCLUDE