Module Name: src Committed By: pooka Date: Sat May 1 14:40:36 UTC 2010
Modified Files: src/sys/rump/include/rump: rump.h src/sys/rump/librump/rumpkern: rump.c Log Message: Add rump_printevcnts() which dumps values from all event counters. (NOTE! it is run unscheduled for various experimentation etcetc. reasons) To generate a diff of this commit: cvs rdiff -u -r1.41 -r1.42 src/sys/rump/include/rump/rump.h cvs rdiff -u -r1.169 -r1.170 src/sys/rump/librump/rumpkern/rump.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/rump/include/rump/rump.h diff -u src/sys/rump/include/rump/rump.h:1.41 src/sys/rump/include/rump/rump.h:1.42 --- src/sys/rump/include/rump/rump.h:1.41 Mon Apr 26 23:40:22 2010 +++ src/sys/rump/include/rump/rump.h Sat May 1 14:40:36 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: rump.h,v 1.41 2010/04/26 23:40:22 pooka Exp $ */ +/* $NetBSD: rump.h,v 1.42 2010/05/01 14:40:36 pooka Exp $ */ /* * Copyright (c) 2007 Antti Kantee. All Rights Reserved. @@ -103,6 +103,8 @@ void rump_schedule(void); void rump_unschedule(void); +void rump_printevcnts(void); + int rump__init(int); #ifndef _RUMPKERNEL Index: src/sys/rump/librump/rumpkern/rump.c diff -u src/sys/rump/librump/rumpkern/rump.c:1.169 src/sys/rump/librump/rumpkern/rump.c:1.170 --- src/sys/rump/librump/rumpkern/rump.c:1.169 Wed Apr 28 14:51:07 2010 +++ src/sys/rump/librump/rumpkern/rump.c Sat May 1 14:40:36 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: rump.c,v 1.169 2010/04/28 14:51:07 pooka Exp $ */ +/* $NetBSD: rump.c,v 1.170 2010/05/01 14:40:36 pooka Exp $ */ /* * Copyright (c) 2007 Antti Kantee. All Rights Reserved. @@ -28,7 +28,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: rump.c,v 1.169 2010/04/28 14:51:07 pooka Exp $"); +__KERNEL_RCSID(0, "$NetBSD: rump.c,v 1.170 2010/05/01 14:40:36 pooka Exp $"); #include <sys/systm.h> #define ELFSIZE ARCH_ELFSIZE @@ -807,3 +807,17 @@ return __NetBSD_Version__; } + +/* + * Note: may be called unscheduled. Not fully safe since no locking + * of allevents (currently that's not even available). + */ +void +rump_printevcnts() +{ + struct evcnt *ev; + + TAILQ_FOREACH(ev, &allevents, ev_list) + rumpuser_dprintf("%s / %s: %" PRIu64 "\n", + ev->ev_group, ev->ev_name, ev->ev_count); +}