[AArch64][SME] Add predicate for NEON support in streaming mode
authorCullen Rhodes <cullen.rhodes@arm.com>
Wed, 18 Aug 2021 12:46:22 +0000 (12:46 +0000)
committerCullen Rhodes <cullen.rhodes@arm.com>
Mon, 23 Aug 2021 08:48:33 +0000 (08:48 +0000)
Split out from D107903 to remove dependency for D108039 and D108279.

Reviewed By: paulwalker-arm

Differential Revision: https://reviews.llvm.org/D108293

llvm/lib/Target/AArch64/AArch64InstrInfo.td

index 9e7b5a0..0145da8 100644 (file)
@@ -140,6 +140,12 @@ def HasSVE2orStreamingSVE
     : Predicate<"Subtarget->hasSVE2() || Subtarget->hasStreamingSVE()">,
                 AssemblerPredicate<(any_of FeatureSVE2, FeatureStreamingSVE),
                 "streaming-sve or sve2">;
+// A subset of NEON instructions are legal in Streaming SVE execution mode,
+// they should be enabled if either has been specified.
+def HasNEONorStreamingSVE
+    : Predicate<"Subtarget->hasNEON() || Subtarget->hasStreamingSVE()">,
+                AssemblerPredicate<(any_of FeatureNEON, FeatureStreamingSVE),
+                "streaming-sve or neon">;
 def HasRCPC          : Predicate<"Subtarget->hasRCPC()">,
                                  AssemblerPredicate<(all_of FeatureRCPC), "rcpc">;
 def HasAltNZCV       : Predicate<"Subtarget->hasAlternativeNZCV()">,