Add definitions for AMD's bobcat (aka btver1)

llvm-svn: 147849
This commit is contained in:
Benjamin Kramer 2012-01-10 11:50:18 +00:00
parent edbc59a27e
commit 569f215771
1 changed files with 18 additions and 2 deletions

View File

@ -1319,12 +1319,20 @@ class X86TargetInfo : public TargetInfo {
CK_Opteron, CK_Opteron,
CK_OpteronSSE3, CK_OpteronSSE3,
CK_AMDFAM10, CK_AMDFAM10,
//@}
/// \name K10 /// \name Bobcat
/// K10 architecture processors. /// Bobcat architecture processors.
//@{
CK_BTVER1,
//@}
/// \name Bulldozer
/// Bulldozer architecture processors.
//@{ //@{
CK_BDVER1, CK_BDVER1,
CK_BDVER2, CK_BDVER2,
//@}
/// This specification is deprecated and will be removed in the future. /// This specification is deprecated and will be removed in the future.
/// Users should prefer \see CK_K8. /// Users should prefer \see CK_K8.
@ -1436,6 +1444,7 @@ public:
.Case("opteron", CK_Opteron) .Case("opteron", CK_Opteron)
.Case("opteron-sse3", CK_OpteronSSE3) .Case("opteron-sse3", CK_OpteronSSE3)
.Case("amdfam10", CK_AMDFAM10) .Case("amdfam10", CK_AMDFAM10)
.Case("btver1", CK_BTVER1)
.Case("bdver1", CK_BDVER1) .Case("bdver1", CK_BDVER1)
.Case("bdver2", CK_BDVER2) .Case("bdver2", CK_BDVER2)
.Case("x86-64", CK_x86_64) .Case("x86-64", CK_x86_64)
@ -1500,6 +1509,7 @@ public:
case CK_Opteron: case CK_Opteron:
case CK_OpteronSSE3: case CK_OpteronSSE3:
case CK_AMDFAM10: case CK_AMDFAM10:
case CK_BTVER1:
case CK_BDVER1: case CK_BDVER1:
case CK_BDVER2: case CK_BDVER2:
case CK_x86_64: case CK_x86_64:
@ -1639,6 +1649,9 @@ void X86TargetInfo::getDefaultFeatures(llvm::StringMap<bool> &Features) const {
setFeatureEnabled(Features, "sse4a", true); setFeatureEnabled(Features, "sse4a", true);
setFeatureEnabled(Features, "3dnowa", true); setFeatureEnabled(Features, "3dnowa", true);
break; break;
case CK_BTVER1:
setFeatureEnabled(Features, "ssse3", true);
setFeatureEnabled(Features, "sse4a", true);
case CK_BDVER1: case CK_BDVER1:
case CK_BDVER2: case CK_BDVER2:
setFeatureEnabled(Features, "sse4", true); setFeatureEnabled(Features, "sse4", true);
@ -1951,6 +1964,9 @@ void X86TargetInfo::getTargetDefines(const LangOptions &Opts,
case CK_AMDFAM10: case CK_AMDFAM10:
defineCPUMacros(Builder, "amdfam10"); defineCPUMacros(Builder, "amdfam10");
break; break;
case CK_BTVER1:
defineCPUMacros(Builder, "btver1");
break;
case CK_BDVER1: case CK_BDVER1:
defineCPUMacros(Builder, "bdver1"); defineCPUMacros(Builder, "bdver1");
break; break;