From: Mag G. <mag...@gm...> - 2010-11-11 13:17:47
|
Hello, I was wondering if anyone measured kernel latency with oprofile. The things I want to measure are: how much extra overhead a module occupies when loaded (and not loaded), latency (or time) a packet takes from application to kernel and to the NIC. |
From: Arnaldo C. de M. <ac...@gh...> - 2010-11-11 17:04:41
|
Em Thu, Nov 11, 2010 at 08:17:41AM -0500, Mag Gam escreveu: > I was wondering if anyone measured kernel latency with oprofile. The > things I want to measure are: how much extra overhead a module > occupies when loaded (and not loaded), That is too generic, some questions: What subsystem this module registers to? If it is just a driver for something not used by your workloads the impact is just some chunk of memory that could otherwise be used for other purposes, which in most cases is negligible. Or do you mean comparing the performance difference of enabling some feature as module or statically building it? > latency (or time) a packet takes from application to kernel and to > the NIC. I suggest you google for lnlat in my nettaps directory, it uses systemtap to hook in packet lifetime points. A bit old, so you may need to add more hooks. Another suggestion for something more recent is for you to take a look at a trace script contributed by Koki Sanagi (Cced): [root@aninha postfix]# perf trace --list | grep packet netdev-times [tx] [rx] [dev=] [debug] display a process of packet and processing time [root@aninha postfix]# It uses the networking tracepoints in recent kernels, that you also can tap into using systemtap. - Arnaldo |
From: William C. <wc...@re...> - 2010-11-11 18:39:49
|
On 11/11/2010 11:06 AM, Arnaldo Carvalho de Melo wrote: > Em Thu, Nov 11, 2010 at 08:17:41AM -0500, Mag Gam escreveu: >> I was wondering if anyone measured kernel latency with oprofile. The >> things I want to measure are: how much extra overhead a module >> occupies when loaded (and not loaded), OProfile performs sampling which isn't so useful for measuring latency. OProfile strength is showing hotspots in the code. The hotspot shown could be things like cpu cycles, branches, cache misses. > > That is too generic, some questions: > > What subsystem this module registers to? If it is just a driver for > something not used by your workloads the impact is just some chunk of > memory that could otherwise be used for other purposes, which in most > cases is negligible. > > Or do you mean comparing the performance difference of enabling some > feature as module or statically building it? > >> latency (or time) a packet takes from application to kernel and to >> the NIC. > > I suggest you google for lnlat in my nettaps directory, it uses > systemtap to hook in packet lifetime points. A bit old, so you may need > to add more hooks. Arnaldo, The following link found in web search for nettaps seems to be dead. Is there somewhere else to find the nettaps.tar.bz2? http://oops.ghostprotocols.net:81/acme/nettaps.tar.bz2 > > Another suggestion for something more recent is for you to take a look > at a trace script contributed by Koki Sanagi (Cced): > > [root@aninha postfix]# perf trace --list | grep packet > netdev-times [tx] [rx] [dev=] [debug] display a process of packet and processing time > [root@aninha postfix]# > > It uses the networking tracepoints in recent kernels, that you also can > tap into using systemtap. > > - Arnaldo Yes, systemtap and the tracepoints are more likely to give you information about the latency between events. -Will |
From: Arnaldo C. de M. <ac...@gh...> - 2010-11-12 03:59:10
|
Em Thu, Nov 11, 2010 at 01:39:40PM -0500, William Cohen escreveu: > On 11/11/2010 11:06 AM, Arnaldo Carvalho de Melo wrote: > > Em Thu, Nov 11, 2010 at 08:17:41AM -0500, Mag Gam escreveu: > > I suggest you google for lnlat in my nettaps directory, it uses > > systemtap to hook in packet lifetime points. A bit old, so you may need > > to add more hooks. > Arnaldo, The following link found in web search for nettaps seems to > be dead. Is there somewhere else to find the nettaps.tar.bz2? > http://oops.ghostprotocols.net:81/acme/nettaps.tar.bz2 http://git.kernel.org/?p=linux/kernel/git/acme/nettaps.git - Arnaldo |