[llvm] 2e7aed1 - [MemorySSA][NFC] Simplify if condition
via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 6 00:47:43 PDT 2022
Author: luxufan
Date: 2022-09-05T10:43:17Z
New Revision: 2e7aed1947d2b280ef76466049af78e49472db40
URL: https://github.com/llvm/llvm-project/commit/2e7aed1947d2b280ef76466049af78e49472db40
DIFF: https://github.com/llvm/llvm-project/commit/2e7aed1947d2b280ef76466049af78e49472db40.diff
LOG: [MemorySSA][NFC] Simplify if condition
Differential Revision: https://reviews.llvm.org/D133332
Added:
Modified:
llvm/include/llvm/Analysis/MemorySSA.h
Removed:
################################################################################
diff --git a/llvm/include/llvm/Analysis/MemorySSA.h b/llvm/include/llvm/Analysis/MemorySSA.h
index c0ceab39433de..ac1daf8b0580c 100644
--- a/llvm/include/llvm/Analysis/MemorySSA.h
+++ b/llvm/include/llvm/Analysis/MemorySSA.h
@@ -1252,8 +1252,7 @@ class upward_defs_iterator
// to unknown guarantees that any memory accesses that access locations
// after the pointer are considered as clobbers, which is important to
// catch loop carried dependences.
- if (Location.Ptr &&
- !IsGuaranteedLoopInvariant(const_cast<Value *>(Location.Ptr)))
+ if (!IsGuaranteedLoopInvariant(const_cast<Value *>(Location.Ptr)))
CurrentPair.second =
Location.getWithNewSize(LocationSize::beforeOrAfterPointer());
PHITransAddr Translator(
More information about the llvm-commits
mailing list