[PATCH] D97998: [CSSPGO] llvm-profdata support for CS profile.

Wenlei He via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 4 23:21:03 PST 2021


wenlei added inline comments.


================
Comment at: llvm/tools/llvm-profdata/llvm-profdata.cpp:701
     ProfileIsProbeBased = FunctionSamples::ProfileIsProbeBased;
+    if (ProfileIsCS && ProfileIsCS != FunctionSamples::ProfileIsCS)
+      exitWithError("cannot merge CS profile with non-CS profile");
----------------
I see explicit hasValue() call used all over the place for Optional values, and I also feel it's more readable to spell it out instead of relying on operator(). Not sure if it's an established convention though.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D97998



More information about the llvm-commits mailing list