[PATCH] D109036: [CSSPGO] Sort function offset table to speed up profile loading.

Wenlei He via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 31 23:08:05 PDT 2021


wenlei added inline comments.


================
Comment at: llvm/lib/ProfileData/SampleProfReader.cpp:813
+
+      if (OrderedFuncOffsets.get()) {
+        for (auto &NameOffset : *OrderedFuncOffsets)
----------------
When suggesting the removal of ordered switch, I was thinking about always have ordered offset table for extbin CSSPGO profile. The simplification in implementation is the main reason I think removing that switch is better.

The idea is that we don't need unnecessary flexibility, so we can make assumptions about CSSPGO profile and avoid the complexity of handling the combinations of different input. With that, we either assert SecFlagOrdered is always on for extbin CSSPGO profile, or remove SecFlagOrdered completely and make that an implicit assumption for extbin CSSPGO profile.  


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D109036



More information about the llvm-commits mailing list