[llvm] 06cfcdc - [AArch64][SVE] Fold variable into assert to silence unused variable warnings in Release builds

Benjamin Kramer via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 15 03:51:14 PST 2020


Author: Benjamin Kramer
Date: 2020-01-15T12:50:27+01:00
New Revision: 06cfcdcca7de9c88a1e885eff0d0c4c07090ad48

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

LOG: [AArch64][SVE] Fold variable into assert to silence unused variable warnings in Release builds

Added: 
    

Modified: 
    llvm/lib/Target/AArch64/AArch64ISelLowering.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp b/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
index 19615550aad7..d45a80057564 100644
--- a/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
+++ b/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
@@ -10895,8 +10895,8 @@ static SDValue getPTest(SelectionDAG &DAG, EVT VT, SDValue Pg, SDValue Op,
   const TargetLowering &TLI = DAG.getTargetLoweringInfo();
 
   SDLoc DL(Op);
-  EVT OpVT = Op.getValueType();
-  assert(OpVT.isScalableVector() && TLI.isTypeLegal(OpVT) &&
+  assert(Op.getValueType().isScalableVector() &&
+         TLI.isTypeLegal(Op.getValueType()) &&
          "Expected legal scalable vector type!");
 
   // Ensure target specific opcodes are using legal type.


        


More information about the llvm-commits mailing list