[PATCH] D142668: [BOLT] Add isParentOf and isSiblingOf BinaryFunction methods
Amir Ayupov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Feb 16 16:04:02 PST 2023
Amir added inline comments.
================
Comment at: bolt/include/bolt/Core/BinaryFunction.h:1840
+ /// Returns if this function is a parent or child of \p Other function.
+ bool isSiblingOf(const BinaryFunction &Other) const {
+ return isChildOf(Other) || isParentOf(Other);
----------------
rafauler wrote:
> sibling?
Yes, it's a bit confusing term, but it's useful in context of stripped binaries where we can't tell which function is a parent and which is a child, hence sibling (as we treat them as equal). For parent-child relationship, I don't know of a good unambiguous term: "isRelativeOf"? Kins? isParentOrChildOf? I would go with sibling unless you strongly disagree.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D142668/new/
https://reviews.llvm.org/D142668
More information about the llvm-commits
mailing list