diff options
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Target/AArch64/AArch64.td | 5 | ||||
| -rw-r--r-- | llvm/lib/Target/AArch64/AArch64Subtarget.h | 2 | ||||
| -rw-r--r-- | llvm/lib/Target/AArch64/AArch64SystemOperands.td | 4 |
3 files changed, 8 insertions, 3 deletions
diff --git a/llvm/lib/Target/AArch64/AArch64.td b/llvm/lib/Target/AArch64/AArch64.td index a092c63325f..e331fee7144 100644 --- a/llvm/lib/Target/AArch64/AArch64.td +++ b/llvm/lib/Target/AArch64/AArch64.td @@ -306,6 +306,9 @@ def FeatureFRInt3264 : SubtargetFeature<"fptoint", "HasFRInt3264", "true", def FeatureSpecRestrict : SubtargetFeature<"specrestrict", "HasSpecRestrict", "true", "Enable architectural speculation restriction" >; +def FeatureSSBS : SubtargetFeature<"ssbs", "HasSSBS", + "true", "Enable Speculative Store Bypass Safe bit" >; + def FeatureSpecCtrl : SubtargetFeature<"specctrl", "HasSpecCtrl", "true", "Enable speculation control barrier" >; @@ -349,7 +352,7 @@ def HasV8_4aOps : SubtargetFeature<"v8.4a", "HasV8_4aOps", "true", def HasV8_5aOps : SubtargetFeature< "v8.5a", "HasV8_5aOps", "true", "Support ARM v8.5a instructions", [HasV8_4aOps, FeatureAltFPCmp, FeatureFRInt3264, FeatureSpecRestrict, - FeatureSpecCtrl, FeaturePredCtrl, FeatureCacheDeepPersist, + FeatureSSBS, FeatureSpecCtrl, FeaturePredCtrl, FeatureCacheDeepPersist, FeatureBranchTargetId] >; diff --git a/llvm/lib/Target/AArch64/AArch64Subtarget.h b/llvm/lib/Target/AArch64/AArch64Subtarget.h index c5850e80274..5e0657d5431 100644 --- a/llvm/lib/Target/AArch64/AArch64Subtarget.h +++ b/llvm/lib/Target/AArch64/AArch64Subtarget.h @@ -127,6 +127,7 @@ protected: bool HasFRInt3264 = false; bool HasSpecRestrict = false; bool HasSpecCtrl = false; + bool HasSSBS = false; bool HasPredCtrl = false; bool HasCCDP = false; bool HasBTI = false; @@ -355,6 +356,7 @@ public: bool hasFRInt3264() const { return HasFRInt3264; } bool hasSpecRestrict() const { return HasSpecRestrict; } bool hasSpecCtrl() const { return HasSpecCtrl; } + bool hasSSBS() const { return HasSSBS; } bool hasPredCtrl() const { return HasPredCtrl; } bool hasCCDP() const { return HasCCDP; } bool hasBTI() const { return HasBTI; } diff --git a/llvm/lib/Target/AArch64/AArch64SystemOperands.td b/llvm/lib/Target/AArch64/AArch64SystemOperands.td index f562bba1d2e..60d48e4d99d 100644 --- a/llvm/lib/Target/AArch64/AArch64SystemOperands.td +++ b/llvm/lib/Target/AArch64/AArch64SystemOperands.td @@ -343,7 +343,7 @@ def : PState<"UAO", 0b00011>; let Requires = [{ {AArch64::FeatureDIT} }] in def : PState<"DIT", 0b11010>; // v8.5a Spectre Mitigation -let Requires = [{ {AArch64::FeatureSpecRestrict} }] in +let Requires = [{ {AArch64::FeatureSSBS} }] in def : PState<"SSBS", 0b11001>; // v8.5a Memory Tagging Extension let Requires = [{ {AArch64::FeatureMTE} }] in @@ -1444,7 +1444,7 @@ def : RWSysReg<"ZCR_EL12", 0b11, 0b101, 0b0001, 0b0010, 0b000>; // V8.5a Spectre mitigation SSBS register // Op0 Op1 CRn CRm Op2 -let Requires = [{ {AArch64::FeatureSpecRestrict} }] in +let Requires = [{ {AArch64::FeatureSSBS} }] in def : RWSysReg<"SSBS", 0b11, 0b011, 0b0100, 0b0010, 0b110>; // v8.5a Memory Tagging Extension |

