[llvm] 709d03f - [LVI] Clarify getValueAt/getValueInBlock doc comments (NFC)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Sun Sep 27 09:23:40 PDT 2020
Author: Nikita Popov
Date: 2020-09-27T18:21:19+02:00
New Revision: 709d03f8af4da4204849a70f01798e7cebba2e32
URL: https://github.com/llvm/llvm-project/commit/709d03f8af4da4204849a70f01798e7cebba2e32
DIFF: https://github.com/llvm/llvm-project/commit/709d03f8af4da4204849a70f01798e7cebba2e32.diff
LOG: [LVI] Clarify getValueAt/getValueInBlock doc comments (NFC)
The lattice value returned by getValueInBlock() holds at the start
of the block, not at the end. Also make it clearer what the
difference between getValueInBlock() and getValueAt() is.
Added:
Modified:
llvm/lib/Analysis/LazyValueInfo.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Analysis/LazyValueInfo.cpp b/llvm/lib/Analysis/LazyValueInfo.cpp
index 475b7189a0b2..667cfd377217 100644
--- a/llvm/lib/Analysis/LazyValueInfo.cpp
+++ b/llvm/lib/Analysis/LazyValueInfo.cpp
@@ -434,14 +434,16 @@ class LazyValueInfoImpl {
void solve();
public:
- /// This is the query interface to determine the lattice
- /// value for the specified Value* at the end of the specified block.
+ /// This is the query interface to determine the lattice value for the
+ /// specified Value* at the context instruction (if specified) or at the
+ /// start of the block.
ValueLatticeElement getValueInBlock(Value *V, BasicBlock *BB,
Instruction *CxtI = nullptr);
- /// This is the query interface to determine the lattice
- /// value for the specified Value* at the specified instruction (generally
- /// from an assume intrinsic).
+ /// This is the query interface to determine the lattice value for the
+ /// specified Value* at the specified instruction using only information
+ /// from assumes/guards and range metadata. Unlike getValueInBlock(), no
+ /// recursive query is performed.
ValueLatticeElement getValueAt(Value *V, Instruction *CxtI);
/// This is the query interface to determine the lattice
More information about the llvm-commits
mailing list