[llvm] 93122b2 - [ARM] Don't look through pointer types in canTailPredicateLoop()

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 28 00:34:22 PST 2022


Author: Nikita Popov
Date: 2022-01-28T09:34:13+01:00
New Revision: 93122b25673b3b8256d372f04d3813b3e93bc643

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

LOG: [ARM] Don't look through pointer types in canTailPredicateLoop()

Inspecting the pointer element type here is incompatible with
opaque pointers, and doesn't seem necessary to me. I think the
intention might have been to check the type of load/store pointer
arguments, but I believe those should get checked through their
return type or value operand anyway. I don't get any test failures
if I simply drop this.

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

Added: 
    

Modified: 
    llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp b/llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp
index e0750a9945d2b..d9d563ead2605 100644
--- a/llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp
+++ b/llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp
@@ -2109,9 +2109,6 @@ static bool canTailPredicateLoop(Loop *L, LoopInfo *LI, ScalarEvolution &SE,
       }
 
       Type *T  = I.getType();
-      if (T->isPointerTy())
-        T = T->getPointerElementType();
-
       if (T->getScalarSizeInBits() > 32) {
         LLVM_DEBUG(dbgs() << "Unsupported Type: "; T->dump());
         return false;


        


More information about the llvm-commits mailing list