[PATCH] D75617: [WPD] Provide a way to prevent function(s) from being devirtualized

Eugene Leviant via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 5 08:45:40 PST 2020


evgeny777 added a comment.

>   if we didn't summarize foo, then we would incorrectly perform a single impl devirt to bar, when we shouldn't have devirtualized at all. 

True

> Or are you saying something different?

Actually I wanted to say that if we prevent `foo` from devirtualizing and have two call sites:

CS1: { foo, bar }
CS2: { bar, baz }

then CS2 will still be devirtulized, so specifying `-wholeprogramdevirt-skip=foo` is actually telling WPD that all call sites potentially calling `foo` should remain virtual.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D75617/new/

https://reviews.llvm.org/D75617





More information about the llvm-commits mailing list