source: trunk/include/cpuhlp.h@ 10367

Last change on this file since 10367 was 8991, checked in by sandervl, 23 years ago

fixed wrong declaration

File size: 1.3 KB
RevLine 
[8991]1/* $Id: cpuhlp.h,v 1.8 2002-08-13 09:39:56 sandervl Exp $ */
[2615]2
3#ifndef _CPUHLP_H_
4#define _CPUHLP_H_
5
[6242]6#include <float.h>
7
[2615]8#ifdef __cplusplus
9extern "C" {
10#endif
11
12#define BIT(a) (1<<a)
13
14#define CPUID_FPU_PRESENT BIT(0)
15#define CPUID_VMMODE_EXTENSIONS BIT(1)
16#define CPUID_DBG_EXTENSIONS BIT(2)
17#define CPUID_PAGE_SIZE_EXTENSIONS BIT(3)
18#define CPUID_TIME_STAMP_COUNTER BIT(4)
19#define CPUID_K86_MODEL_REGS BIT(5)
20#define CPUID_MACHINE_CHECK_EXCEPTION BIT(7)
21#define CPUID_CMPXCHG8B_INSTRUCTION BIT(8)
22#define CPUID_APIC BIT(9)
23#define CPUID_MEMORY_TYPE_RANGE_REGS BIT(12)
24#define CPUID_GLOBAL_PAGING_EXTENSIONS BIT(13)
25#define CPUID_CONDITIONAL_MOVE BIT(15)
26#define CPUID_MMX BIT(23)
27
[4406]28BOOL CDECL SupportsCPUID();
[2615]29
[4406]30void CDECL GetCPUVendorString(char *vendor);
31DWORD CDECL GetCPUFeatures();
32DWORD CDECL GetCPUSignature();
[8991]33void CDECL GetTSC(LONG *pdwLow, LONG *pdwHigh);
[2615]34
35void InitSystemInfo(int nrcpus);
36
37extern DWORD CPUFeatures;
38
[5090]39#if (__IBMC__ >= 360) || (__IBMCPP__ >= 360)
40#define CONTROL87(a,b) __control87(a, b)
41#else
42#if (__IBMCPP__ == 300) || (__IBMC__ == 300)
43#define CONTROL87(a,b) _control87(a, b)
44#else
[8448]45#ifdef __WATCOMC__
46#define CONTROL87(a,b) _control87(a, b)
47#else
[5090]48#error CONTROL87 undefined
49#endif
50#endif
[8448]51#endif
[5090]52
[2615]53#ifdef __cplusplus
54}
55#endif
56
57#endif /* _CPUHLP_H_ */
58
Note: See TracBrowser for help on using the repository browser.