Pyrogenesis HEAD
Pyrogenesis, a RTS Engine
x86_x64.cpp File Reference
#include "precompiled.h"
#include "lib/sysdep/arch/x86_x64/x86_x64.h"
#include <cstring>
#include <cstdio>
#include <vector>
#include <set>
#include <algorithm>
#include "lib/posix/posix_pthread.h"
#include "lib/bits.h"
#include "lib/timer.h"
#include "lib/module_init.h"
#include "lib/sysdep/cpu.h"
#include "lib/sysdep/os_cpu.h"
Include dependency graph for x86_x64.cpp:

Classes

class  x86_x64::StringStripper
 functor to remove substrings from the CPU identifier string More...
 
class  x86_x64::ScopedSetPriority
 

Namespaces

namespace  x86_x64
 

Functions

static void x86_x64::Invoke_cpuid (CpuidRegs *regs)
 
static Status x86_x64::InitCpuid ()
 
bool x86_x64::cpuid (CpuidRegs *regs)
 invoke CPUID instruction. More...
 
static Status x86_x64::InitCaps ()
 
bool x86_x64::Cap (Caps cap)
 
void x86_x64::GetCapBits (u32 *d0, u32 *d1, u32 *d2, u32 *d3)
 
static Status x86_x64::InitVendor ()
 
Vendors x86_x64::Vendor ()
 
static Status x86_x64::InitSignature ()
 
size_t x86_x64::Model ()
 
size_t x86_x64::Family ()
 
static Status x86_x64::InitIdentifierString ()
 
static const char * x86_x64::IdentifierString ()
 
u64 x86_x64::rdtsc ()
 
void x86_x64::DebugBreak ()
 trigger a breakpoint inside this function when it is called. More...
 
double x86_x64::ClockFrequency ()
 measure the CPU clock frequency via rdtsc and timer_Time. More...
 
const char * cpu_IdentifierString ()
 Routines specific to E2K (MCST Elbrus 2000) More...
 

Variables

static u32 x86_x64::cpuid_maxFunction
 
static u32 x86_x64::cpuid_maxExtendedFunction
 
static u32 x86_x64::caps [4]
 
static ModuleInitState x86_x64::capsInitState { 0 }
 
static Vendors x86_x64::vendor
 
static size_t x86_x64::m_Model
 
static size_t x86_x64::m_Family
 
static ModuleInitState x86_x64::signatureInitState { 0 }
 
static char x86_x64::identifierString [48+1]
 

Function Documentation

◆ cpu_IdentifierString()

const char * cpu_IdentifierString ( )

Routines specific to E2K (MCST Elbrus 2000)

Returns
string identifying the CPU (usually a cleaned-up version of the brand string)