[llvm] [AArch64] Lower disjoint_or+not to eon. (PR #147279)

Ricardo Jesus via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 7 09:22:16 PDT 2025


================
@@ -30,3 +30,24 @@ entry:
   %shl2 = shl i64 %xor, %xor1
   ret i64 %shl2
 }
+
+; Check that eon is generated if the xor is a disjoint or.
+define i64 @disjoint_or(i64 %a, i64 %b) {
+; CHECK-LABEL: disjoint_or:
+; CHECK: eon
+; CHECK: ret
+  %or = or disjoint i64 %a, %b
----------------
rj-jesus wrote:

No worries at all - it seems we can use the BSL instructions for quite a few more interesting cases such as NOT (unpredicated), ORN, EON, NAND and NOR! :smile: 

https://github.com/llvm/llvm-project/pull/147279


More information about the llvm-commits mailing list