summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--llvm/lib/Target/X86/X86.td8
-rw-r--r--llvm/test/CodeGen/X86/bitcnt-false-dep.ll8
2 files changed, 11 insertions, 5 deletions
diff --git a/llvm/lib/Target/X86/X86.td b/llvm/lib/Target/X86/X86.td
index aa1470ebf51..7ca77b13942 100644
--- a/llvm/lib/Target/X86/X86.td
+++ b/llvm/lib/Target/X86/X86.td
@@ -563,7 +563,8 @@ class SilvermontProc<string Name> : ProcessorModel<Name, SLMModel, [
FeatureSlowIncDec,
FeatureSlowPMULLD,
FeatureRDRAND,
- FeatureLAHFSAHF
+ FeatureLAHFSAHF,
+ FeaturePOPCNTFalseDeps
]>;
def : SilvermontProc<"silvermont">;
def : SilvermontProc<"slm">; // Legacy alias.
@@ -607,7 +608,10 @@ def GLMFeatures : ProcessorFeatures<[], [
]>;
class GoldmontProc<string Name> : ProcModel<Name, SLMModel,
- GLMFeatures.Value, [ ProcIntelGLM ]>;
+ GLMFeatures.Value, [
+ ProcIntelGLM,
+ FeaturePOPCNTFalseDeps
+]>;
def : GoldmontProc<"goldmont">;
class GoldmontPlusProc<string Name> : ProcModel<Name, SLMModel,
diff --git a/llvm/test/CodeGen/X86/bitcnt-false-dep.ll b/llvm/test/CodeGen/X86/bitcnt-false-dep.ll
index a6e4c148f1b..2527db6cae6 100644
--- a/llvm/test/CodeGen/X86/bitcnt-false-dep.ll
+++ b/llvm/test/CodeGen/X86/bitcnt-false-dep.ll
@@ -1,6 +1,8 @@
-; RUN: llc < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=haswell -mattr=+lzcnt | FileCheck %s --check-prefix=HSW
-; RUN: llc < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=skylake -mattr=+lzcnt | FileCheck %s --check-prefix=SKL
-; RUN: llc < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=skx -mattr=+lzcnt | FileCheck %s --check-prefix=SKL
+; RUN: llc < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=haswell | FileCheck %s --check-prefix=HSW
+; RUN: llc < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=skylake | FileCheck %s --check-prefix=SKL
+; RUN: llc < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=skx | FileCheck %s --check-prefix=SKL
+; RUN: llc < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=silvermont -mattr=+lzcnt,+bmi | FileCheck %s --check-prefix=SKL
+; RUN: llc < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=goldmont -mattr=+lzcnt,+bmi | FileCheck %s --check-prefix=SKL
; This tests a fix for bugzilla 33869 https://bugs.llvm.org/show_bug.cgi?id=33869
OpenPOWER on IntegriCloud