27 #ifndef INCLUDED_X86_X64 28 #define INCLUDED_X86_X64 31 #error "including x86_x64.h without ARCH_X86_X64=1" 43 #pragma pack(push, 1) // (allows casting to int*) 160 static inline u64 rdtsc() {
return __rdtsc(); }
180 #endif // #ifndef INCLUDED_X86_X64 Definition: x86_x64.h:121
double ClockFrequency()
measure the CPU clock frequency via rdtsc and timer_Time.
Definition: x86_x64.cpp:429
u32 ecx
Definition: x86_x64.h:48
Definition: x86_x64.h:124
Definition: x86_x64.h:135
Definition: x86_x64.h:125
bool cpuid(CpuidRegs *regs)
invoke CPUID instruction.
Definition: x86_x64.cpp:98
void DebugBreak()
trigger a breakpoint inside this function when it is called.
Definition: x86_x64.cpp:385
Definition: x86_x64.h:119
Definition: x86_x64.h:122
Definition: x86_x64.h:127
u32 edx
Definition: x86_x64.h:49
uint64_t u64
Definition: types.h:40
Definition: x86_x64.h:134
Definition: x86_x64.h:112
size_t Family()
Definition: x86_x64.cpp:238
Definition: x86_x64.h:116
Definition: x86_x64.h:114
uint32_t u32
Definition: types.h:39
Definition: x86_x64.h:136
Models
Definition: x86_x64.h:80
Caps
bit indices of CPU capability flags (128 bits).
Definition: x86_x64.h:109
u64 rdtsc()
Definition: x86_x64.cpp:373
bool Cap(Caps cap)
Definition: x86_x64.cpp:142
u32 ebx
Definition: x86_x64.h:47
Definition: x86_x64.h:113
Definition: x86_x64.h:120
Definition: x86_x64.h:130
void GetCapBits(u32 *d0, u32 *d1, u32 *d2, u32 *d3)
Definition: x86_x64.cpp:156
Definition: x86_x64.cpp:47
Definition: x86_x64.h:123
u32 eax
Definition: x86_x64.h:46
Definition: x86_x64.h:126
size_t Model()
Definition: x86_x64.cpp:232
registers used/returned by cpuid
Definition: x86_x64.h:44
Vendors Vendor()
Definition: x86_x64.cpp:200
Definition: x86_x64.h:133
Vendors
CPU vendor.
Definition: x86_x64.h:70
Definition: x86_x64.h:115