Index: lib/Target/X86/X86.td =================================================================== --- lib/Target/X86/X86.td +++ lib/Target/X86/X86.td @@ -376,6 +376,7 @@ FeatureSlowBTMem, FeatureLAHFSAHF ]>; + def : ProcessorModel<"penryn", SandyBridgeModel, [ FeatureX87, FeatureSlowUAMem16, @@ -387,71 +388,69 @@ FeatureLAHFSAHF ]>; -// Atom CPUs. -class BonnellProc : ProcessorModel Inherited, + list NewFeatures> { + list Value = !listconcat(Inherited, NewFeatures); +} + +class ProcModel ProcFeatures, + list OtherFeatures> : + ProcessorModel; + +def AtomFeatures : ProcessorFeatures<[], [ FeatureX87, - FeatureSlowUAMem16, FeatureMMX, - FeatureSSSE3, FeatureFXSR, FeatureCMPXCHG16B, FeatureMOVBE, - FeatureSlowBTMem, - FeatureLEAForSP, - FeatureSlowDivide32, - FeatureSlowDivide64, - FeatureCallRegIndirect, - FeatureLEAUsesAG, - FeaturePadShortFunctions, FeatureLAHFSAHF ]>; -def : BonnellProc<"bonnell">; -def : BonnellProc<"atom">; // Pin the generic name to the baseline. -class SilvermontProc : ProcessorModel; + +// Atom CPUs. +class BonnellProc : ProcModel; +def : BonnellProc<"bonnell">; +def : BonnellProc<"atom">; // Pin the generic name to the baseline. + +class SilvermontProc : ProcModel; def : SilvermontProc<"silvermont">; def : SilvermontProc<"slm">; // Legacy alias. -class GoldmontProc : ProcessorModel : ProcModel; def : WestmereProc<"westmere">; -class ProcessorFeatures Inherited, - list NewFeatures> { - list Value = !listconcat(Inherited, NewFeatures); -} -class ProcModel ProcFeatures, - list OtherFeatures> : - ProcessorModel; // SSE is not listed here since llvm treats AVX as a reimplementation of SSE, // rather than a superset.