Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 03 Jun 2015 16:11:07 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-bugs@FreeBSD.org
Subject:   [Bug 200616] pmcstat runs out of buckets
Message-ID:  <bug-200616-8@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=200616

            Bug ID: 200616
           Summary: pmcstat runs out of buckets
           Product: Base System
           Version: 11.0-CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: kern
          Assignee: freebsd-bugs@FreeBSD.org
          Reporter: hselasky@FreeBSD.org

Hi,

It has been observed that pmcstat can run out of buckets leading to an assert,
when converting trace data into gprof compatible format. Applying the following
patch, temporarily solves the problem:

diff --git a/usr.sbin/pmcstat/pmcpl_gprof.c b/usr.sbin/pmcstat/pmcpl_gprof.c
index 9ff78e8..4a8849f 100644
--- a/usr.sbin/pmcstat/pmcpl_gprof.c
+++ b/usr.sbin/pmcstat/pmcpl_gprof.c
@@ -445,8 +445,8 @@ pmcpl_gmon_process(struct pmcstat_process *pp, struct
pmcstat_pmcrecord *pmcr,
                image, pmcid);
            pgf->pgf_pmcid = pmcid;
            assert(image->pi_end > image->pi_start);
-               pgf->pgf_nbuckets = (image->pi_end - image->pi_start) /
-                   FUNCTION_ALIGNMENT; /* see <machine/profile.h> */
+               pgf->pgf_nbuckets = (image->pi_end - image->pi_start); // /
+       //                  FUNCTION_ALIGNMENT; /* see <machine/profile.h> */
            pgf->pgf_ndatabytes = sizeof(struct gmonhdr) +
                pgf->pgf_nbuckets * sizeof(HISTCOUNTER);
            pgf->pgf_nsamples = 0; 

--HPS

-- 
You are receiving this mail because:
You are the assignee for the bug.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-200616-8>