Re: [RFC] Light weight event counters (V2) instead of page state

From: Christoph Lameter
Date: Tue Jun 13 2006 - 11:22:53 EST


On Tue, 13 Jun 2006, Martin Peschke wrote:

> Did you consider using the statistics infrastructure available in -mm?
> (lib/statistic.c, include/linux/statistic.h, Documentation/statistics.txt)

No its not in Linus tree and has even more overhead than the existing
counters since it always checks if a certain counters is on or off and it
also does indirect calls to an update function.

It does not use local_t at all and takes an smp_processor_id() parameter
to various functions which makes the future use of cpu_local_* functions
not possible (should that implementation get fixed).

> 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.

The light weight counter implementation here provides the output of
/proc/vmstat. That is a fixed interface.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/