[PATCH] D18468: Profile summary cleanup.

Easwaran Raman via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 28 10:50:17 PDT 2016


eraman added inline comments.

================
Comment at: include/llvm/ProfileData/ProfileCommon.h:153
@@ -153,4 +152,3 @@
   uint64_t getTotalSamples() { return TotalCount; }
-  uint32_t getNumFunctions() { return NumFunctions; }
-  uint64_t getMaxHeadSamples() { return MaxHeadSamples; }
+  uint64_t getMaxHeadSamples() { return MaxFunctionCount; }
   uint64_t getMaxSamplesPerLine() { return MaxCount; }
----------------
danielcdh wrote:
> dnovillo wrote:
> > Perhaps we should deprecate getMaxHeadSamples?  IIUC, MaxFunctionCount is the number of times a function was called, correct?  That's essentially the same information provided by counting the number of samples in the function header.
> > 
> > There is a difference between the two, but I don't think the distinction is worth keeping.  Dehao, what do you think?
> Agree, MaxHeadSamples should be the same as MaxFunctionCount.
I thought it is useful in terms of readability to have interfaces named in SampleProfile specific terms. Both MaxHeadSamples and MaxFunctionCount are indeed same and hence getMaxHeadSamples returns the MaxFunctionCount. If this is causing confusion, I'll deprecate this in a separate change.


http://reviews.llvm.org/D18468





More information about the llvm-commits mailing list