summaryrefslogtreecommitdiffstats
path: root/sys/sys/gmon.h
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2006-03-29 18:17:03 +0000
committerjhb <jhb@FreeBSD.org>2006-03-29 18:17:03 +0000
commitabde52e5ce80edbdd681c86c97f94e86fb5a49a4 (patch)
tree8ca2fc28d38b37db33356a4b16fbb7a2e1eb8955 /sys/sys/gmon.h
parentfc54b4c09076eae2b71d8a829e7833ce948805ca (diff)
downloadFreeBSD-src-abde52e5ce80edbdd681c86c97f94e86fb5a49a4.zip
FreeBSD-src-abde52e5ce80edbdd681c86c97f94e86fb5a49a4.tar.gz
Move the PC_TO_I() and KCOUNT() macros so they aren't GUPROF specific
since they operate on fields of struct gmonparam which is not GUPROF specific. Approved by: bde Reported by: alc
Diffstat (limited to 'sys/sys/gmon.h')
-rw-r--r--sys/sys/gmon.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/sys/gmon.h b/sys/sys/gmon.h
index ac405ab..1fb8507 100644
--- a/sys/sys/gmon.h
+++ b/sys/sys/gmon.h
@@ -200,13 +200,14 @@ extern struct gmonparam _gmonparam;
#ifdef _KERNEL
-#ifdef GUPROF
-
-#define CALIB_SCALE 1000
#define KCOUNT(p,index) \
((p)->kcount[(index) / (HISTFRACTION * sizeof(HISTCOUNTER))])
#define PC_TO_I(p, pc) ((uintfptr_t)(pc) - (uintfptr_t)(p)->lowpc)
+#ifdef GUPROF
+
+#define CALIB_SCALE 1000
+
extern int cputime_bias;
int cputime(void);
OpenPOWER on IntegriCloud