summaryrefslogtreecommitdiff
path: root/ipc/ipc_mqueue.c
diff options
context:
space:
mode:
authorDavid Höppner <0xffea@gmail.com>2013-01-04 22:43:53 +0000
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2013-01-13 20:13:32 +0100
commitbeda83efaa45fb04f142034f61eb1ae9fe872c59 (patch)
treeb5e4a7a4b18e42feb24d46167028f8cf3130b557 /ipc/ipc_mqueue.c
parent392239d8c9979ac95c122b77d5d1e012f216d2ec (diff)
Add statistics for task_events_info
* ipc/ipc_mqueue.c (ipc_mqueue_send, ipc_mqueue_receive): Increment counters for message sent and received. * kern/ipc_kobject.c (ipc_kobject_server): Increment sent and received counters for the kernel task. * kern/task.c (task_create): Zero statistics. * kern/task.c (task_info): Add task_events_info call. * kern/task.h: Add statistics. * vm/vm_fault.c (vm_fault_page): Increment zero_fills, pageins, reactivations and cow_faults counters. * vm/vm_fault.c (vm_fault_wire_fast): Increment faults counters. * vm/vm_pageout.c (vm_pageout_scan): Increment reactivations counter.
Diffstat (limited to 'ipc/ipc_mqueue.c')
-rw-r--r--ipc/ipc_mqueue.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/ipc/ipc_mqueue.c b/ipc/ipc_mqueue.c
index f3d5d4b..80a34d3 100644
--- a/ipc/ipc_mqueue.c
+++ b/ipc/ipc_mqueue.c
@@ -374,6 +374,8 @@ ipc_mqueue_send(kmsg, option, time_out)
}
}
+ current_task()->messages_sent++;
+
return MACH_MSG_SUCCESS;
}
@@ -684,6 +686,8 @@ ipc_mqueue_receive(
ip_unlock(port);
}
+ current_task()->messages_received++;
+
*kmsgp = kmsg;
*seqnop = seqno;
return MACH_MSG_SUCCESS;