Messages in this thread | | | Date | Tue, 13 Jun 2006 15:57:10 +0200 | From | Martin Peschke <> | Subject | Re: [RFC] Light weight event counters (V2) instead of page state |
| |
Christoph Lameter wrote: > We would like to have some solution that reduces the > overhead for these counters. VM counters currently require interrupt disabling > in order to work. Maybe we can avoid that by using the local_t which provides > an increment operation that is not atomic vs other processors but atomic vs > interrupts on this same processor. > > The patchset also adds an off switch for embedded systems that allows a > building of linux kernels without these counters.
Did you consider using the statistics infrastructure available in -mm? (lib/statistic.c, include/linux/statistic.h, Documentation/statistics.txt)
It's a ready-to-use statistics library that comes with similar characteristics as you have described above.
> The remaining counters in page_state after the zoned VM counter patch has > been applied are all just for show in /proc/vmstat. They have no essential > function for the VM.
To me that looks like a good application for the statistics infrastructure, which shows statistics through debugfs instead of procfs. Btw., it completely unburdens exploiting kernel code from the delivery of statistics to users.
Martin
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |