Tutorial :performance tool


I basically have a unix process running and it is doing some heavy processing as well as outputting data over the network. I was wondering what system calls are used to interact with the networking layer.

I would like to measure the performance metrics of this process: CPU usage, networking usage. I am not sure if this process is blocked because it is writing way too fast to the networking layer or if this process is spending too much time processing code.

Any suggestions?



What you really need is a profiler. That way, you'll be able to see which parts of your code are taking the most time.

Try http://oprofile.sourceforge.net/, or a specific profiler for your toolchain.

As a quick measurement you can try running your process under strace to see which system calls it makes and see live how long they take.


What Unix? Solaris/FreeBSD/OSX have dtrace, Linux has oprofile. All of them have tcpdump for you to analyze the network flow.


I suggest valgrind which is another profiler.

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Next Post »