================
@@ -3173,6 +3179,23 @@ let Predicates = [HasAVX512] in {
def : Pat<(v1i1 immAllOnesV), (COPY_TO_REGCLASS (KSET1W), VK1)>;
}
+// With AVX512DQ, use 8-bit operations for 8-bit masks to avoid setting upper
+// bits
+let Predicates = [HasDQI] in {
+ def : Pat<(v8i1 immAllZerosV), (KSET0B)>;
+ def : Pat<(v8i1 immAllOnesV), (KSET1B)>;
----------------
ahmednoursphinx wrote:
No, primarily due to predicate specificity, not order.
`HasDQI` is more restrictive than `HasAVX512`, so the `KSET1B` pattern wins on
DQI targets regardless of order. Pattern order only matters as a tie-breaker
when predicate specificity is equal.
https://github.com/llvm/llvm-project/pull/166178
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits