[PATCH] D42311: [SyntheticCounts] Rewrite the code using only graph traits.

Xinliang David Li via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 22 16:22:56 PST 2018


On Mon, Jan 22, 2018 at 4:01 PM, Daniel Berlin via Phabricator <
reviews at reviews.llvm.org> wrote:

> dberlin added a comment.
>
> I don't understand why you need has_function_def. It looks very much like
> a thing you should just be using a filter_iterator for or something. It
> does not look like it belongs in the graphtraits at all.
>
>
Is it assuming the NodeRef of different callgraph types all have the same
interface to check whether the node is defined, otherwise how to form a
generic predicate for the filter_iterator?

On the other hand, check body availability seems like a common operation
for all callgraph implementations, so having a generic interface in traits
seems making sense?

David


>
> Repository:
>   rL LLVM
>
> https://reviews.llvm.org/D42311
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180122/8c0a164c/attachment.html>


More information about the llvm-commits mailing list