[PATCH] D132186: Clang: Add a new flag Wmisnoinline for printing hot noinline functions

Di Mo via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 20 11:30:07 PDT 2022


modimo added a comment.

In D132186#3802989 <https://reviews.llvm.org/D132186#3802989>, @paulkirth wrote:

> @iamarchit123 I think the standard advice is to start w/ the llvm-test-suite and then explore other benchmarks as needed. Also, Clang itself is often a very good starting point.
>
> As for profiles, it probably won't be representative, but you could collect the profile using your benchmark and then assess how often the mismatch w/ inlining happens. if you want to do it w/ Clang itself, then a common approach I've heard is to record have Clang build your project and then use ninja trace or equivalent to find the 5-10 TUs w/ the longest compile time. Then stick them in the https://github.com/llvm/llvm-project/tree/main/clang/utils/perf-training directory, which will use them for PGO automatically. If you go that route, you may need to preprocess the source files.

+1 Clang is the best starting point. I've been busy recently so haven't had a chance to run the HHVM experiments, starting a run today. Paul left some good review comments that you can address without requiring performance runs--I would recommend getting the patch updated so when the results come back everything will be ready to commit.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D132186



More information about the cfe-commits mailing list