[PATCH] D139150: [DomTree] Add docstring for `dominates(const Instruction*, const BasicBlock*)`. NFC
Michael Maitland via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 1 15:18:11 PST 2022
michaelmaitland created this revision.
michaelmaitland added reviewers: kuhar, reames, nikic, arsenm.
Herald added a project: All.
michaelmaitland requested review of this revision.
Herald added subscribers: llvm-commits, wdng.
Herald added a project: LLVM.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D139150
Files:
llvm/include/llvm/IR/Dominators.h
Index: llvm/include/llvm/IR/Dominators.h
===================================================================
--- llvm/include/llvm/IR/Dominators.h
+++ llvm/include/llvm/IR/Dominators.h
@@ -196,8 +196,12 @@
/// Return true if value Def dominates all possible uses inside instruction
/// User. Same comments as for the Use-based API apply.
bool dominates(const Value *Def, const Instruction *User) const;
- // Does not accept Value to avoid ambiguity with dominance checks between
- // two basic blocks.
+
+ /// Returns true if Def would dominate a use in any instruction in BB.
+ /// If Def is an instruction in BB, then Def does not dominate BB.
+ ///
+ /// Does not accept Value to avoid ambiguity with dominance checks between
+ /// two basic blocks.
bool dominates(const Instruction *Def, const BasicBlock *BB) const;
/// Return true if an edge dominates a use.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D139150.479449.patch
Type: text/x-patch
Size: 889 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221201/066eef71/attachment.bin>
More information about the llvm-commits
mailing list