aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/accounting/taskstats-struct.txt
diff options
context:
space:
mode:
authorMaxim Uvarov <muvarov@ru.mvista.com>2007-07-16 02:40:48 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-07-16 12:05:46 -0400
commitb663a79c191508f27cd885224b592a878c0ba0f6 (patch)
tree270a0472bf1fb0c7323ecb60ec68e40d02dcb1b4 /Documentation/accounting/taskstats-struct.txt
parenta6c15c2b0fbfd5c0a84f5f0e1e3f20f85d2b8692 (diff)
taskstats: add context-switch counters
Make available to the user the following task and process performance statistics: * Involuntary Context Switches (task_struct->nivcsw) * Voluntary Context Switches (task_struct->nvcsw) Statistics information is available from: 1. taskstats interface (Documentation/accounting/) 2. /proc/PID/status (task only). This data is useful for detecting hyperactivity patterns between processes. [akpm@linux-foundation.org: cleanup] Signed-off-by: Maxim Uvarov <muvarov@ru.mvista.com> Cc: Shailabh Nagar <nagar@watson.ibm.com> Cc: Balbir Singh <balbir@in.ibm.com> Cc: Jay Lan <jlan@engr.sgi.com> Cc: Jonathan Lim <jlim@sgi.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'Documentation/accounting/taskstats-struct.txt')
-rw-r--r--Documentation/accounting/taskstats-struct.txt6
1 files changed, 6 insertions, 0 deletions
diff --git a/Documentation/accounting/taskstats-struct.txt b/Documentation/accounting/taskstats-struct.txt
index 661c797eaf79..8aa7529f8258 100644
--- a/Documentation/accounting/taskstats-struct.txt
+++ b/Documentation/accounting/taskstats-struct.txt
@@ -22,6 +22,8 @@ There are three different groups of fields in the struct taskstats:
22 /* Extended accounting fields end */ 22 /* Extended accounting fields end */
23 Their values are collected if CONFIG_TASK_XACCT is set. 23 Their values are collected if CONFIG_TASK_XACCT is set.
24 24
254) Per-task and per-thread context switch count statistics
26
25Future extension should add fields to the end of the taskstats struct, and 27Future extension should add fields to the end of the taskstats struct, and
26should not change the relative position of each field within the struct. 28should not change the relative position of each field within the struct.
27 29
@@ -158,4 +160,8 @@ struct taskstats {
158 160
159 /* Extended accounting fields end */ 161 /* Extended accounting fields end */
160 162
1634) Per-task and per-thread statistics
164 __u64 nvcsw; /* Context voluntary switch counter */
165 __u64 nivcsw; /* Context involuntary switch counter */
166
161} 167}