Custom Search
Showing posts with label Linux. Show all posts
Showing posts with label Linux. Show all posts

Tuesday, May 19, 2009

GUI for Valgrind



Callgrind uses runtime instrumentation via the Valgrind framework for its cache simulation and call-graph generation. This way, even shared libraries and dynamically opened plugins can be profiled. The data files generated by Callgrind can be loaded into KCachegrind for browsing the performance results. But there is also a command line tool in the package to get ASCII reports from data files without the need to use KCachegrind.

Link

Saturday, February 28, 2009

How to Print Shared Library Dependencies

ldd prints the shared libraries required by each program or shared library specified on the command line.

To see all modules dependencies use the command ldd [options] filename

Linux Command Line to format c source file

In Linux system you can use this command line to format your c source file :

> indent -i4 -ts4 -br -brs -cdw -lp -ce -nbfda -npcs -nprs -npsl -nbbo -saf -sai -saw -cs -l90 foo.c

You may want to put these settings in your ~/.indent.pro to automatically invoke this configuration next time.

In verbose, the above means:

* -i4: indent level 4
* -ts4: tab size 4
* -br: braces on if line
* -brs: braces on struct decl line
* -cdw: cuddle do while
* -lp: line up continuation below parenthesis
* -ce: cuddle else
* -nbfda: dont break function decl args
* -npcs: no space after function call names
* -nprs: no space after parentheses
* -npsl: dont break procedure type
* -saf: space after for
* -sai: space after if
* -saw: space after while
* -cs: space after cast
* -ln90: line length 90 columns

Sunday, May 21, 2006

The Code Linux