[Mono-dev] [PATCH] Network Performance Counters - V2

Joel Reed joelwreed at gmail.com
Sat Oct 10 17:17:47 EDT 2009


This is version 2 of my network performance counters patch. I rebased it 
onto the 20091009 daily tarball.

Per Gonzalo's comments seen here: 
http://www.mail-archive.com/mono-devel-list@lists.ximian.com/msg22135.html, 
I've:

1) Modified where I free the values returned by 
mono_networkinterface_list().

2) Moved mono_networkinterface_list() to utils/mono-networkinterfaces.c

As a reminder, the attached patch implements 3 "Network Interface" 
performance category counters. The counters are "Bytes Received/sec", 
"Bytes Sent/sec", and "Bytes Total/sec". A sample program using these 
counters and sample output is attached as well.

This information is obtained by reading /proc/net/dev.

Here's the diffstat for the patch:

  metadata/ChangeLog               |    6 +
  metadata/mono-perfcounters-def.h |    4 +
  metadata/mono-perfcounters.c     |   92 ++++++++++++++++++++++++++
  utils/ChangeLog                  |    5 +
  utils/Makefile.am                |    2
  utils/Makefile.in                |   10 +-
  utils/mono-networkinterfaces.c   |  134 
+++++++++++++++++++++++++++++++++++++++
  utils/mono-networkinterfaces.h   |   28 ++++++++
  8 files changed, 277 insertions(+), 4 deletions(-)

Thanks,

jr

-------------- next part --------------
A non-text attachment was scrubbed...
Name: PerfMon.cs
Type: text/x-csharp
Size: 2125 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20091010/1e66ef29/attachment.bin 
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: output.txt
Url: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20091010/1e66ef29/attachment.txt 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: network-perfcounters.v2.patch
Type: text/x-diff
Size: 12918 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20091010/1e66ef29/attachment-0001.bin 


More information about the Mono-devel-list mailing list