mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-03-04 21:10:32 +00:00
Merge pull request #996 from Winterleaf/Add-new-cpus-AMD-Types
Added support for AMD Chips
This commit is contained in:
commit
183fe7dbeb
3 changed files with 26 additions and 2 deletions
|
|
@ -74,6 +74,9 @@ enum ProcessorType
|
|||
CPU_AMD_K6_2,
|
||||
CPU_AMD_K6_3,
|
||||
CPU_AMD_Athlon,
|
||||
CPU_AMD_Phenom,
|
||||
CPU_AMD_PhenomII,
|
||||
CPU_AMD_Bulldozer,
|
||||
CPU_AMD_Unknown,
|
||||
CPU_Cyrix_6x86,
|
||||
CPU_Cyrix_MediaGX,
|
||||
|
|
|
|||
|
|
@ -92,8 +92,8 @@ public:
|
|||
exit conditions.
|
||||
*/
|
||||
#define AssertFatal(x, y) \
|
||||
{ if (((bool)(x))==(bool)0) \
|
||||
{ if ( ::PlatformAssert::processAssert(::PlatformAssert::Fatal, __FILE__, __LINE__, y) ) { ::Platform::debugBreak(); } } }
|
||||
{ if (((bool)(x))==false) \
|
||||
{ if ( ::PlatformAssert::processAssert(::PlatformAssert::Fatal, __FILE__, __LINE__, y) ) { ::Platform::debugBreak(); } } }
|
||||
|
||||
#else
|
||||
#define AssertFatal(x, y) { TORQUE_UNUSED(x); TORQUE_UNUSED(y); }
|
||||
|
|
|
|||
|
|
@ -178,6 +178,9 @@ void SetProcessorInfo(Platform::SystemInfo_struct::Processor& pInfo,
|
|||
pInfo.properties |= (properties & BIT_SSE) ? CPU_PROP_SSE : 0;
|
||||
pInfo.properties |= ( properties & BIT_SSE2 ) ? CPU_PROP_SSE2 : 0;
|
||||
pInfo.properties |= (properties & BIT_3DNOW) ? CPU_PROP_3DNOW : 0;
|
||||
// Phenom and PhenomII support SSE3, SSE4a
|
||||
pInfo.properties |= ( properties2 & BIT_SSE3 ) ? CPU_PROP_SSE3 : 0;
|
||||
pInfo.properties |= ( properties2 & BIT_SSE4_1 ) ? CPU_PROP_SSE4_1 : 0;
|
||||
// switch on processor family code
|
||||
switch ((processor >> 8) & 0xf)
|
||||
{
|
||||
|
|
@ -223,6 +226,24 @@ void SetProcessorInfo(Platform::SystemInfo_struct::Processor& pInfo,
|
|||
pInfo.name = StringTable->insert("AMD Athlon");
|
||||
break;
|
||||
|
||||
// Phenom Family
|
||||
case 15:
|
||||
pInfo.type = CPU_AMD_Phenom;
|
||||
pInfo.name = StringTable->insert("AMD Phenom");
|
||||
break;
|
||||
|
||||
// Phenom II Family
|
||||
case 16:
|
||||
pInfo.type = CPU_AMD_PhenomII;
|
||||
pInfo.name = StringTable->insert("AMD Phenom II");
|
||||
break;
|
||||
|
||||
// Bulldozer Family
|
||||
case 17:
|
||||
pInfo.type = CPU_AMD_Bulldozer;
|
||||
pInfo.name = StringTable->insert("AMD Bulldozer");
|
||||
break;
|
||||
|
||||
default:
|
||||
pInfo.type = CPU_AMD_Unknown;
|
||||
pInfo.name = StringTable->insert("AMD (unknown)");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue