[llvm] [NFCI] Check for non-null before dereferencing a VPBB ptr (PR #190403)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Sat Apr 4 14:13:59 PDT 2026


================
@@ -410,10 +410,12 @@ bool vputils::isUniformAcrossVFsAndUFs(VPValue *V) {
     return all_of(R->operands(), isUniformAcrossVFsAndUFs);
   }
 
-  if (VPRegionBlock *EnclosingRegion = VPBB->getEnclosingLoopRegion()) {
-    // Canonical IV is uniform.
-    if (V == EnclosingRegion->getCanonicalIV())
-      return true;
+  if (VPBB) {
----------------
fhahn wrote:

Can we merge this with the code above that is also conditional on VPBB?

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


More information about the llvm-commits mailing list