mirror of
https://github.com/ZDoom/qzdoom.git
synced 2025-05-31 17:10:51 +00:00
- Fixed: The aliasing of CPUInfo was still wrong. (Yarr! The things I do
for you, GCC!) The AMD feature flags weren't stored anywhere, either; not that it really matters. SVN r1794 (trunk)
This commit is contained in:
parent
b528b987da
commit
7da43069d7
3 changed files with 13 additions and 10 deletions
|
@ -2,6 +2,9 @@ September 5, 2009 (Changes by Graf Zahl)
|
||||||
- made menu dimming a mapping option but kept the CVARS as user override.
|
- made menu dimming a mapping option but kept the CVARS as user override.
|
||||||
|
|
||||||
September 4, 2009
|
September 4, 2009
|
||||||
|
- Fixed: The aliasing of CPUInfo was still wrong. (Yarr! The things I do
|
||||||
|
for you, GCC!) The AMD feature flags weren't stored anywhere, either; not
|
||||||
|
that it really matters.
|
||||||
- Add an alternate PIC-compliant __cpuid macro in x86.cpp.
|
- Add an alternate PIC-compliant __cpuid macro in x86.cpp.
|
||||||
- Fixed: S_LoadSound() did not byte-swap the frequency and length it reads
|
- Fixed: S_LoadSound() did not byte-swap the frequency and length it reads
|
||||||
from DMX sounds.
|
from DMX sounds.
|
||||||
|
|
|
@ -96,9 +96,9 @@ haveid:
|
||||||
|
|
||||||
// Get vendor ID
|
// Get vendor ID
|
||||||
__cpuid(foo, 0);
|
__cpuid(foo, 0);
|
||||||
cpu->VendorID[0] = foo[1];
|
cpu->dwVendorID[0] = foo[1];
|
||||||
cpu->VendorID[1] = foo[3];
|
cpu->dwVendorID[1] = foo[3];
|
||||||
cpu->VendorID[2] = foo[2];
|
cpu->dwVendorID[2] = foo[2];
|
||||||
if (foo[1] == MAKE_ID('A','u','t','h') &&
|
if (foo[1] == MAKE_ID('A','u','t','h') &&
|
||||||
foo[3] == MAKE_ID('e','n','t','i') &&
|
foo[3] == MAKE_ID('e','n','t','i') &&
|
||||||
foo[2] == MAKE_ID('c','A','M','D'))
|
foo[2] == MAKE_ID('c','A','M','D'))
|
||||||
|
@ -162,9 +162,9 @@ haveid:
|
||||||
cpu->AMDFamily += (foo[0] >> 20) & 0xFF;
|
cpu->AMDFamily += (foo[0] >> 20) & 0xFF;
|
||||||
cpu->AMDModel |= (foo[0] >> 12) & 0xF0;
|
cpu->AMDModel |= (foo[0] >> 12) & 0xF0;
|
||||||
}
|
}
|
||||||
|
cpu->FeatureFlags[3] = foo[3]; // AMD feature flags
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
12
src/x86.h
12
src/x86.h
|
@ -21,15 +21,15 @@ struct CPUInfo // 92 bytes
|
||||||
BYTE Family;
|
BYTE Family;
|
||||||
BYTE Type;
|
BYTE Type;
|
||||||
|
|
||||||
BYTE BrandIndex;
|
|
||||||
BYTE CLFlush;
|
|
||||||
BYTE CPUCount;
|
|
||||||
BYTE APICID;
|
|
||||||
|
|
||||||
union
|
union
|
||||||
{
|
{
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
|
BYTE BrandIndex;
|
||||||
|
BYTE CLFlush;
|
||||||
|
BYTE CPUCount;
|
||||||
|
BYTE APICID;
|
||||||
|
|
||||||
DWORD bSSE3:1;
|
DWORD bSSE3:1;
|
||||||
DWORD DontCare1:8;
|
DWORD DontCare1:8;
|
||||||
DWORD bSSSE3:1;
|
DWORD bSSSE3:1;
|
||||||
|
@ -78,7 +78,7 @@ struct CPUInfo // 92 bytes
|
||||||
DWORD b3DNowPlus:1;
|
DWORD b3DNowPlus:1;
|
||||||
DWORD b3DNow:1;
|
DWORD b3DNow:1;
|
||||||
};
|
};
|
||||||
DWORD FeatureFlags[3];
|
DWORD FeatureFlags[4];
|
||||||
};
|
};
|
||||||
|
|
||||||
BYTE AMDStepping;
|
BYTE AMDStepping;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue