Richard Boegli's CnC_Generals_Zero_Hour Fork WIP
This is documentation of Richard Boegil's Zero Hour Fork
 
Loading...
Searching...
No Matches
CPUDetectClass Class Reference

#include <cpudetect.h>

Public Types

enum  ProcessorManufacturerType {
  MANUFACTURER_UNKNOWN = 0 , MANUFACTURER_INTEL , MANUFACTURER_UMC , MANUFACTURER_AMD ,
  MANUFACTURER_CYRIX , MANUFACTURER_NEXTGEN , MANUFACTURER_VIA , MANUFACTURER_RISE ,
  MANUFACTURER_TRANSMETA
}
 
enum  IntelProcessorType {
  INTEL_PROCESSOR_UNKNOWN , INTEL_PROCESSOR_80386 , INTEL_PROCESSOR_80486DX , INTEL_PROCESSOR_80486SX ,
  INTEL_PROCESSOR_80486DX2 , INTEL_PROCESSOR_80486SL , INTEL_PROCESSOR_80486SX2 , INTEL_PROCESSOR_80486DX2_WB ,
  INTEL_PROCESSOR_80486DX4 , INTEL_PROCESSOR_80486DX4_WB , INTEL_PROCESSOR_PENTIUM , INTEL_PROCESSOR_PENTIUM_OVERDRIVE ,
  INTEL_PROCESSOR_PENTIUM_MMX , INTEL_PROCESSOR_PENTIUM_PRO_SAMPLE , INTEL_PROCESSOR_PENTIUM_PRO , INTEL_PROCESSOR_PENTIUM_II_OVERDRIVE ,
  INTEL_PROCESSOR_PENTIUM_II_MODEL_3 , INTEL_PROCESSOR_PENTIUM_II_MODEL_4 , INTEL_PROCESSOR_CELERON_MODEL_5 , INTEL_PROCESSOR_PENTIUM_II_MODEL_5 ,
  INTEL_PROCESSOR_PENTIUM_II_XEON_MODEL_5 , INTEL_PROCESSOR_CELERON_MODEL_6 , INTEL_PROCESSOR_PENTIUM_III_MODEL_7 , INTEL_PROCESSOR_PENTIUM_III_XEON_MODEL_7 ,
  INTEL_PROCESSOR_CELERON_MODEL_8 , INTEL_PROCESSOR_PENTIUM_III_MODEL_8 , INTEL_PROCESSOR_PENTIUM_III_XEON_MODEL_8 , INTEL_PROCESSOR_PENTIUM_III_XEON_MODEL_A ,
  INTEL_PROCESSOR_PENTIUM_III_MODEL_B , INTEL_PROCESSOR_PENTIUM4
}
 
enum  AMDProcessorType {
  AMD_PROCESSOR_UNKNOWN , AMD_PROCESSOR_486DX2 , AMD_PROCESSOR_486DX4 , AMD_PROCESSOR_5x86 ,
  AMD_PROCESSOR_486 , AMD_PROCESSOR_K5_MODEL0 , AMD_PROCESSOR_K5_MODEL1 , AMD_PROCESSOR_K5_MODEL2 ,
  AMD_PROCESSOR_K5_MODEL3 , AMD_PROCESSOR_K6_MODEL6 , AMD_PROCESSOR_K6_MODEL7 , AMD_PROCESSOR_K6_2_3DNOW_MODEL8 ,
  AMD_PROCESSOR_K6_3_3DNOW_MODEL9 , AMD_PROCESSOR_K6_3_PLUS , AMD_PROCESSOR_K6 , AMD_PROCESSOR_ATHLON_025 ,
  AMD_PROCESSOR_ATHLON_018 , AMD_PROCESSOR_DURON , AMD_PROCESSOR_ATHLON_018_IL2 , AMD_PROCESSOR_ATHLON
}
 
enum  VIAProcessorType {
  VIA_PROCESSOR_UNKNOWN , VIA_PROCESSOR_IDT_C6_WINCHIP , VIA_PROCESSOR_IDT_C6_WINCHIP2 , VIA_PROCESSOR_IDT_C6_WINCHIP3 ,
  VIA_PROCESSOR_CYRIX_III_SAMUEL
}
 
enum  RiseProcessorType {
  RISE_PROCESSOR_UNKNOWN , RISE_PROCESSOR_DRAGON_025 , RISE_PROCESSOR_DRAGON_018 , RISE_PROCESSOR_DRAGON2_025 ,
  RISE_PROCESSOR_DRAGON2_018
}
 

Static Public Member Functions

static ProcessorManufacturerType Get_Processor_Manufacturer ()
 
static const char * Get_Processor_Manufacturer_Name ()
 
static bool Has_CPUID_Instruction ()
 
static bool Has_RDTSC_Instruction ()
 
static bool Has_CMOV_Instruction ()
 
static bool Has_MMX_Instruction_Set ()
 
static bool Has_SSE_Instruction_Set ()
 
static bool Has_SSE2_Instruction_Set ()
 
static bool Has_3DNow_Instruction_Set ()
 
static bool Has_Extended_3DNow_Instruction_Set ()
 
static IntelProcessorType Get_Intel_Processor ()
 
static AMDProcessorType Get_AMD_Processor ()
 
static VIAProcessorType Get_VIA_Processor ()
 
static RiseProcessorType Get_Rise_Processor ()
 
static int Get_Processor_Speed ()
 
static sint64 Get_Processor_Ticks_Per_Second ()
 
static double Get_Inv_Processor_Ticks_Per_Second ()
 
static unsigned Get_Feature_Bits ()
 
static unsigned Get_Extended_Feature_Bits ()
 
static unsigned Get_L2_Cache_Size ()
 
static unsigned Get_L2_Cache_Line_Size ()
 
static unsigned Get_L2_Cache_Set_Associative ()
 
static unsigned Get_L1_Data_Cache_Size ()
 
static unsigned Get_L1_Data_Cache_Line_Size ()
 
static unsigned Get_L1_Data_Cache_Set_Associative ()
 
static unsigned Get_L1_Instruction_Cache_Size ()
 
static unsigned Get_L1_Instruction_Cache_Line_Size ()
 
static unsigned Get_L1_Instruction_Cache_Set_Associative ()
 
static unsigned Get_L1_Instruction_Trace_Cache_Size ()
 
static unsigned Get_L1_Instruction_Trace_Cache_Set_Associative ()
 
static unsigned Get_Total_Physical_Memory ()
 
static unsigned Get_Available_Physical_Memory ()
 
static unsigned Get_Total_Page_File_Size ()
 
static unsigned Get_Available_Page_File_Size ()
 
static unsigned Get_Total_Virtual_Memory ()
 
static unsigned Get_Available_Virtual_Memory ()
 
static unsigned Get_Processor_Type ()
 
static const char * Get_Processor_String ()
 
static const StringClassGet_Processor_Log ()
 
static const StringClassGet_Compact_Log ()
 
static bool CPUID (unsigned &u_eax_, unsigned &u_ebx_, unsigned &u_ecx_, unsigned &u_edx_, unsigned cpuid_type)
 

Friends

class CPUDetectInitClass
 

Detailed Description

Definition at line 57 of file cpudetect.h.

Member Enumeration Documentation

◆ AMDProcessorType

Enumerator
AMD_PROCESSOR_UNKNOWN 
AMD_PROCESSOR_486DX2 
AMD_PROCESSOR_486DX4 
AMD_PROCESSOR_5x86 
AMD_PROCESSOR_486 
AMD_PROCESSOR_K5_MODEL0 
AMD_PROCESSOR_K5_MODEL1 
AMD_PROCESSOR_K5_MODEL2 
AMD_PROCESSOR_K5_MODEL3 
AMD_PROCESSOR_K6_MODEL6 
AMD_PROCESSOR_K6_MODEL7 
AMD_PROCESSOR_K6_2_3DNOW_MODEL8 
AMD_PROCESSOR_K6_3_3DNOW_MODEL9 
AMD_PROCESSOR_K6_3_PLUS 
AMD_PROCESSOR_K6 
AMD_PROCESSOR_ATHLON_025 
AMD_PROCESSOR_ATHLON_018 
AMD_PROCESSOR_DURON 
AMD_PROCESSOR_ATHLON_018_IL2 
AMD_PROCESSOR_ATHLON 

Definition at line 107 of file cpudetect.h.

◆ IntelProcessorType

Enumerator
INTEL_PROCESSOR_UNKNOWN 
INTEL_PROCESSOR_80386 
INTEL_PROCESSOR_80486DX 
INTEL_PROCESSOR_80486SX 
INTEL_PROCESSOR_80486DX2 
INTEL_PROCESSOR_80486SL 
INTEL_PROCESSOR_80486SX2 
INTEL_PROCESSOR_80486DX2_WB 
INTEL_PROCESSOR_80486DX4 
INTEL_PROCESSOR_80486DX4_WB 
INTEL_PROCESSOR_PENTIUM 
INTEL_PROCESSOR_PENTIUM_OVERDRIVE 
INTEL_PROCESSOR_PENTIUM_MMX 
INTEL_PROCESSOR_PENTIUM_PRO_SAMPLE 
INTEL_PROCESSOR_PENTIUM_PRO 
INTEL_PROCESSOR_PENTIUM_II_OVERDRIVE 
INTEL_PROCESSOR_PENTIUM_II_MODEL_3 
INTEL_PROCESSOR_PENTIUM_II_MODEL_4 
INTEL_PROCESSOR_CELERON_MODEL_5 
INTEL_PROCESSOR_PENTIUM_II_MODEL_5 
INTEL_PROCESSOR_PENTIUM_II_XEON_MODEL_5 
INTEL_PROCESSOR_CELERON_MODEL_6 
INTEL_PROCESSOR_PENTIUM_III_MODEL_7 
INTEL_PROCESSOR_PENTIUM_III_XEON_MODEL_7 
INTEL_PROCESSOR_CELERON_MODEL_8 
INTEL_PROCESSOR_PENTIUM_III_MODEL_8 
INTEL_PROCESSOR_PENTIUM_III_XEON_MODEL_8 
INTEL_PROCESSOR_PENTIUM_III_XEON_MODEL_A 
INTEL_PROCESSOR_PENTIUM_III_MODEL_B 
INTEL_PROCESSOR_PENTIUM4 

Definition at line 73 of file cpudetect.h.

◆ ProcessorManufacturerType

Enumerator
MANUFACTURER_UNKNOWN 
MANUFACTURER_INTEL 
MANUFACTURER_UMC 
MANUFACTURER_AMD 
MANUFACTURER_CYRIX 
MANUFACTURER_NEXTGEN 
MANUFACTURER_VIA 
MANUFACTURER_RISE 
MANUFACTURER_TRANSMETA 

Definition at line 60 of file cpudetect.h.

◆ RiseProcessorType

Enumerator
RISE_PROCESSOR_UNKNOWN 
RISE_PROCESSOR_DRAGON_025 
RISE_PROCESSOR_DRAGON_018 
RISE_PROCESSOR_DRAGON2_025 
RISE_PROCESSOR_DRAGON2_018 

Definition at line 140 of file cpudetect.h.

◆ VIAProcessorType

Enumerator
VIA_PROCESSOR_UNKNOWN 
VIA_PROCESSOR_IDT_C6_WINCHIP 
VIA_PROCESSOR_IDT_C6_WINCHIP2 
VIA_PROCESSOR_IDT_C6_WINCHIP3 
VIA_PROCESSOR_CYRIX_III_SAMUEL 

Definition at line 131 of file cpudetect.h.

Member Function Documentation

◆ CPUID()

bool CPUDetectClass::CPUID ( unsigned & u_eax_,
unsigned & u_ebx_,
unsigned & u_ecx_,
unsigned & u_edx_,
unsigned cpuid_type )
static

Definition at line 935 of file cpudetect.cpp.

◆ Get_AMD_Processor()

static AMDProcessorType CPUDetectClass::Get_AMD_Processor ( )
inlinestatic

Definition at line 164 of file cpudetect.h.

◆ Get_Available_Page_File_Size()

static unsigned CPUDetectClass::Get_Available_Page_File_Size ( )
inlinestatic

Definition at line 200 of file cpudetect.h.

◆ Get_Available_Physical_Memory()

static unsigned CPUDetectClass::Get_Available_Physical_Memory ( )
inlinestatic

Definition at line 198 of file cpudetect.h.

◆ Get_Available_Virtual_Memory()

static unsigned CPUDetectClass::Get_Available_Virtual_Memory ( )
inlinestatic

Definition at line 202 of file cpudetect.h.

◆ Get_Compact_Log()

static const StringClass & CPUDetectClass::Get_Compact_Log ( )
inlinestatic

Definition at line 208 of file cpudetect.h.

◆ Get_Extended_Feature_Bits()

static unsigned CPUDetectClass::Get_Extended_Feature_Bits ( )
inlinestatic

Definition at line 175 of file cpudetect.h.

◆ Get_Feature_Bits()

static unsigned CPUDetectClass::Get_Feature_Bits ( )
inlinestatic

Definition at line 174 of file cpudetect.h.

◆ Get_Intel_Processor()

static IntelProcessorType CPUDetectClass::Get_Intel_Processor ( )
inlinestatic

Definition at line 163 of file cpudetect.h.

◆ Get_Inv_Processor_Ticks_Per_Second()

static double CPUDetectClass::Get_Inv_Processor_Ticks_Per_Second ( )
inlinestatic

Definition at line 172 of file cpudetect.h.

◆ Get_L1_Data_Cache_Line_Size()

static unsigned CPUDetectClass::Get_L1_Data_Cache_Line_Size ( )
inlinestatic

Definition at line 184 of file cpudetect.h.

◆ Get_L1_Data_Cache_Set_Associative()

static unsigned CPUDetectClass::Get_L1_Data_Cache_Set_Associative ( )
inlinestatic

Definition at line 185 of file cpudetect.h.

◆ Get_L1_Data_Cache_Size()

static unsigned CPUDetectClass::Get_L1_Data_Cache_Size ( )
inlinestatic

Definition at line 183 of file cpudetect.h.

◆ Get_L1_Instruction_Cache_Line_Size()

static unsigned CPUDetectClass::Get_L1_Instruction_Cache_Line_Size ( )
inlinestatic

Definition at line 189 of file cpudetect.h.

◆ Get_L1_Instruction_Cache_Set_Associative()

static unsigned CPUDetectClass::Get_L1_Instruction_Cache_Set_Associative ( )
inlinestatic

Definition at line 190 of file cpudetect.h.

◆ Get_L1_Instruction_Cache_Size()

static unsigned CPUDetectClass::Get_L1_Instruction_Cache_Size ( )
inlinestatic

Definition at line 188 of file cpudetect.h.

◆ Get_L1_Instruction_Trace_Cache_Set_Associative()

static unsigned CPUDetectClass::Get_L1_Instruction_Trace_Cache_Set_Associative ( )
inlinestatic

Definition at line 194 of file cpudetect.h.

◆ Get_L1_Instruction_Trace_Cache_Size()

static unsigned CPUDetectClass::Get_L1_Instruction_Trace_Cache_Size ( )
inlinestatic

Definition at line 193 of file cpudetect.h.

◆ Get_L2_Cache_Line_Size()

static unsigned CPUDetectClass::Get_L2_Cache_Line_Size ( )
inlinestatic

Definition at line 179 of file cpudetect.h.

◆ Get_L2_Cache_Set_Associative()

static unsigned CPUDetectClass::Get_L2_Cache_Set_Associative ( )
inlinestatic

Definition at line 180 of file cpudetect.h.

◆ Get_L2_Cache_Size()

static unsigned CPUDetectClass::Get_L2_Cache_Size ( )
inlinestatic

Definition at line 178 of file cpudetect.h.

◆ Get_Processor_Log()

static const StringClass & CPUDetectClass::Get_Processor_Log ( )
inlinestatic

Definition at line 207 of file cpudetect.h.

◆ Get_Processor_Manufacturer()

static ProcessorManufacturerType CPUDetectClass::Get_Processor_Manufacturer ( )
inlinestatic

Definition at line 149 of file cpudetect.h.

◆ Get_Processor_Manufacturer_Name()

const char * CPUDetectClass::Get_Processor_Manufacturer_Name ( )
static

Definition at line 109 of file cpudetect.cpp.

◆ Get_Processor_Speed()

static int CPUDetectClass::Get_Processor_Speed ( )
inlinestatic

Definition at line 170 of file cpudetect.h.

◆ Get_Processor_String()

static const char * CPUDetectClass::Get_Processor_String ( )
inlinestatic

Definition at line 206 of file cpudetect.h.

◆ Get_Processor_Ticks_Per_Second()

static sint64 CPUDetectClass::Get_Processor_Ticks_Per_Second ( )
inlinestatic

Definition at line 171 of file cpudetect.h.

◆ Get_Processor_Type()

static unsigned CPUDetectClass::Get_Processor_Type ( )
inlinestatic

Definition at line 204 of file cpudetect.h.

◆ Get_Rise_Processor()

static RiseProcessorType CPUDetectClass::Get_Rise_Processor ( )
inlinestatic

Definition at line 166 of file cpudetect.h.

◆ Get_Total_Page_File_Size()

static unsigned CPUDetectClass::Get_Total_Page_File_Size ( )
inlinestatic

Definition at line 199 of file cpudetect.h.

◆ Get_Total_Physical_Memory()

static unsigned CPUDetectClass::Get_Total_Physical_Memory ( )
inlinestatic

Definition at line 197 of file cpudetect.h.

◆ Get_Total_Virtual_Memory()

static unsigned CPUDetectClass::Get_Total_Virtual_Memory ( )
inlinestatic

Definition at line 201 of file cpudetect.h.

◆ Get_VIA_Processor()

static VIAProcessorType CPUDetectClass::Get_VIA_Processor ( )
inlinestatic

Definition at line 165 of file cpudetect.h.

◆ Has_3DNow_Instruction_Set()

static bool CPUDetectClass::Has_3DNow_Instruction_Set ( )
inlinestatic

Definition at line 158 of file cpudetect.h.

◆ Has_CMOV_Instruction()

static bool CPUDetectClass::Has_CMOV_Instruction ( )
inlinestatic

Definition at line 154 of file cpudetect.h.

◆ Has_CPUID_Instruction()

static bool CPUDetectClass::Has_CPUID_Instruction ( )
inlinestatic

Definition at line 152 of file cpudetect.h.

◆ Has_Extended_3DNow_Instruction_Set()

static bool CPUDetectClass::Has_Extended_3DNow_Instruction_Set ( )
inlinestatic

Definition at line 159 of file cpudetect.h.

◆ Has_MMX_Instruction_Set()

static bool CPUDetectClass::Has_MMX_Instruction_Set ( )
inlinestatic

Definition at line 155 of file cpudetect.h.

◆ Has_RDTSC_Instruction()

static bool CPUDetectClass::Has_RDTSC_Instruction ( )
inlinestatic

Definition at line 153 of file cpudetect.h.

◆ Has_SSE2_Instruction_Set()

static bool CPUDetectClass::Has_SSE2_Instruction_Set ( )
inlinestatic

Definition at line 157 of file cpudetect.h.

◆ Has_SSE_Instruction_Set()

static bool CPUDetectClass::Has_SSE_Instruction_Set ( )
inlinestatic

Definition at line 156 of file cpudetect.h.

Friends And Related Symbol Documentation

◆ CPUDetectInitClass

friend class CPUDetectInitClass
friend

Definition at line 241 of file cpudetect.h.


The documentation for this class was generated from the following files: