[PATCH] D100470: [LICM][NFC] Fix typo
Marcythm via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 14 05:01:05 PDT 2021
Marcythm created this revision.
Marcythm added a reviewer: nikic.
Herald added subscribers: asbirlea, hiraditya.
Marcythm requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
fix some typo in LICM.cpp
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D100470
Files:
llvm/lib/Transforms/Scalar/LICM.cpp
Index: llvm/lib/Transforms/Scalar/LICM.cpp
===================================================================
--- llvm/lib/Transforms/Scalar/LICM.cpp
+++ llvm/lib/Transforms/Scalar/LICM.cpp
@@ -558,7 +558,7 @@
for (BasicBlock::iterator II = BB->end(); II != BB->begin();) {
Instruction &I = *--II;
- // If the instruction is dead, we would try to sink it because it isn't
+ // If the instruction is dead, we wouldn't try to sink it because it isn't
// used in the loop, instead, just delete it.
if (isInstructionTriviallyDead(&I, TLI)) {
LLVM_DEBUG(dbgs() << "LICM deleting dead inst: " << I << '\n');
@@ -1126,7 +1126,7 @@
isa<InsertValueInst>(I) || isa<FreezeInst>(I));
}
/// Return true if all of the alias sets within this AST are known not to
-/// contain a Mod, or if MSSA knows thare are no MemoryDefs in the loop.
+/// contain a Mod, or if MSSA knows there are no MemoryDefs in the loop.
bool isReadOnly(AliasSetTracker *CurAST, const MemorySSAUpdater *MSSAU,
const Loop *L) {
if (CurAST) {
@@ -1349,13 +1349,12 @@
return false;
} else if (const auto *MD = dyn_cast<MemoryDef>(&MA)) {
if (auto *LI = dyn_cast<LoadInst>(MD->getMemoryInst())) {
- (void)LI; // Silence warning.
assert(!LI->isUnordered() && "Expected unordered load");
return false;
}
// Any call, while it may not be clobbering SI, it may be a use.
if (auto *CI = dyn_cast<CallInst>(MD->getMemoryInst())) {
- // Check if the call may read from the memory locattion written
+ // Check if the call may read from the memory location written
// to by SI. Check CI's attributes and arguments; the number of
// such checks performed is limited above by NoOfMemAccTooLarge.
ModRefInfo MRI = AA->getModRefInfo(CI, MemoryLocation::get(SI));
@@ -2097,7 +2096,7 @@
// Note that proving a load safe to speculate requires proving
// sufficient alignment at the target location. Proving it guaranteed
// to execute does as well. Thus we can increase our guaranteed
- // alignment as well.
+ // alignment as well.
if (!DereferenceableInPH || (InstAlignment > Alignment))
if (isSafeToExecuteUnconditionally(*Load, DT, TLI, CurLoop,
SafetyInfo, ORE,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D100470.337415.patch
Type: text/x-patch
Size: 2517 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210414/23a2d8f5/attachment.bin>
More information about the llvm-commits
mailing list