summaryrefslogtreecommitdiffstats
path: root/sys/sparc64/include/pmap.h
diff options
context:
space:
mode:
authorjake <jake@FreeBSD.org>2003-01-05 05:30:40 +0000
committerjake <jake@FreeBSD.org>2003-01-05 05:30:40 +0000
commit07e8d84aeafc4c536fc3617199cb67ff304769d0 (patch)
tree8143586ff4eede072e84820580516ab704855c8d /sys/sparc64/include/pmap.h
parent2c839e264808090112dce1afcf161ca60c37c325 (diff)
downloadFreeBSD-src-07e8d84aeafc4c536fc3617199cb67ff304769d0.zip
FreeBSD-src-07e8d84aeafc4c536fc3617199cb67ff304769d0.tar.gz
- Reorganize PMAP_STATS to scale a little better.
- Add some more stats for things that are now considered interesting.
Diffstat (limited to 'sys/sparc64/include/pmap.h')
-rw-r--r--sys/sparc64/include/pmap.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/sys/sparc64/include/pmap.h b/sys/sparc64/include/pmap.h
index d0a11fa..a14673e 100644
--- a/sys/sparc64/include/pmap.h
+++ b/sys/sparc64/include/pmap.h
@@ -115,4 +115,23 @@ pmap_track_modified(pmap_t pm, vm_offset_t va)
return (1);
}
+#ifdef PMAP_STATS
+
+SYSCTL_DECL(_debug_pmap_stats);
+
+#define PMAP_STATS_VAR(name) \
+ static long name; \
+ SYSCTL_LONG(_debug_pmap_stats, OID_AUTO, name, CTLFLAG_RD, \
+ &name, 0, "")
+
+#define PMAP_STATS_INC(var) \
+ atomic_add_long(&var, 1)
+
+#else
+
+#define PMAP_STATS_VAR(name)
+#define PMAP_STATS_INC(var)
+
+#endif
+
#endif /* !_MACHINE_PMAP_H_ */
OpenPOWER on IntegriCloud