[PATCH] D32872: [PowerPC] Leverage PGO data to version/expand small/large memcpy calls
Lei Huang via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 10 06:56:18 PST 2018
lei added inline comments.
================
Comment at: lib/Target/PowerPC/PPCLowerMemIntrinsics.cpp:204
+ // Obtain profiling information.
+ ProfileSummaryInfo *PSI =
+ getAnalysis<ProfileSummaryInfoWrapperPass>().getPSI();
----------------
I think we should add this as a member to the class then there is no need to pass it as a param to `shouldExpandmemCpy()`. Not sure about the trade offs to initializing it here vs in `runOnModule`, but since it doesn't have a dependency on the Function it'll only be initialized once per module as opposed to for each `Function` which contains a memcpy.
https://reviews.llvm.org/D32872
More information about the llvm-commits
mailing list