fix watcom feature detect
git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@563 b9cfdab3-6d41-4d17-bbe4-086880011989
This commit is contained in:
parent
f34feaba6d
commit
ab8e44a55d
1 changed files with 4 additions and 3 deletions
|
|
@ -38,13 +38,14 @@ switch(ty) {
|
|||
return vec;
|
||||
}
|
||||
|
||||
#if defined(__WATCOMC__) || defined(__i386__) || defined(__amd64__)
|
||||
#if defined(MwLLMathMMX)
|
||||
static MwU32 getCPUFeatures(void) {
|
||||
MwU32 _eax = 1;
|
||||
MwU32 _edx;
|
||||
|
||||
#ifdef __WATCOMC__
|
||||
__asm {
|
||||
mov eax, _eax
|
||||
cpuid
|
||||
mov _eax, eax
|
||||
mov _edx, edx
|
||||
|
|
@ -70,13 +71,13 @@ static MwLLMathVTable* getMultiTable(int ty) {
|
|||
}
|
||||
|
||||
static MwLLMathVTable* multiTableSetupAndGet(int ty) {
|
||||
#if defined(__WATCOMC__) || defined(__i386__) || defined(__amd64__)
|
||||
#if defined(MwLLMathMMX)
|
||||
MwU32 features;
|
||||
#endif
|
||||
|
||||
mwLLMultiTable = default_multi_table();
|
||||
|
||||
#if defined(__WATCOMC__) || defined(__i386__) || defined(__amd64__)
|
||||
#if defined(MwLLMathMMX)
|
||||
features = getCPUFeatures();
|
||||
printf("Avaliable x86_64 Features:\n");
|
||||
printf("\tMMX: %s\n", features & FEATX86_MMX ? "true" : "false");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue