[llvm] dfd6b69 - [ARM] [TableGen] Clean up !if(!eq(boolean, 1) and related booleans

Paul C. Anagnostopoulos via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 21 06:53:18 PDT 2020


Author: Paul C. Anagnostopoulos
Date: 2020-10-21T09:52:45-04:00
New Revision: dfd6b69e018c88c752e89b504c427718d99e6c8f

URL: https://github.com/llvm/llvm-project/commit/dfd6b69e018c88c752e89b504c427718d99e6c8f
DIFF: https://github.com/llvm/llvm-project/commit/dfd6b69e018c88c752e89b504c427718d99e6c8f.diff

LOG: [ARM] [TableGen] Clean up !if(!eq(boolean, 1) and related booleans

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

Added: 
    

Modified: 
    llvm/lib/Target/ARM/ARMInstrMVE.td

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Target/ARM/ARMInstrMVE.td b/llvm/lib/Target/ARM/ARMInstrMVE.td
index f7f403503dc7..67a3530a7d4e 100644
--- a/llvm/lib/Target/ARM/ARMInstrMVE.td
+++ b/llvm/lib/Target/ARM/ARMInstrMVE.td
@@ -2474,7 +2474,7 @@ multiclass MVE_VABSNEG_int_m<string iname, bit negate, bit saturate,
 
   let Predicates = [HasMVEInt] in {
     // VQABS and VQNEG have more 
diff icult isel patterns defined elsewhere
-    if !eq(saturate, 0) then {
+    if !not(saturate) then {
       def : Pat<(VTI.Vec (unpred_op (VTI.Vec MQPR:$v))),
                 (VTI.Vec (Inst $v))>;
     }
@@ -4777,7 +4777,7 @@ class MVE_VxMOVxN<string iname, string suffix, bit bit_28, bit bit_17,
   let Inst{16} = 0b1;
   let Inst{12} = T;
   let Inst{8} = 0b0;
-  let Inst{7} = !if(!eq(bit_17, 0), 1, 0);
+  let Inst{7} = !not(bit_17);
   let Inst{0} = 0b1;
   let validForTailPredication = 1;
   let retainsPreviousHalfElement = 1;
@@ -4808,7 +4808,7 @@ multiclass MVE_VMOVN_p<Instruction Inst, bit top,
                                (VTI.Vec MQPR:$Qm), (i32 top))),
             (VTI.Vec (Inst (VTI.Vec MQPR:$Qd_src), (VTI.Vec MQPR:$Qm)))>;
 
-  if !eq(top, 0) then {
+  if !not(top) then {
     // If we see MVEvmovn(a,ARMvrev(b),1), that wants to overwrite the odd
     // lanes of a with the odd lanes of b. In other words, the lanes we're
     // _keeping_ from a are the even ones. So we can flip it round and say that


        


More information about the llvm-commits mailing list