Linuxprogrammingblog - linuxprogrammingblog.com - Linux Programming Blog

Latest News:

Profiling Input/Output performance 21 May 2011 | 10:12 pm

There are various nice tools for program profiling when it comes to CPU usage like gprof or oprofile. Those tools will tell you exactly which functions in your code consume most CPU time, where they a...

Complexity of std::list::size() is... O(N) 27 Mar 2011 | 08:57 pm

I want to share my recent "discovery" that was very shocking to me. Reading comments to a slashdot story about the C++0x standard I read something very interesting: std::list::size() has O(N) complexi...

Not so obvious multi-thread programming specific bugs. 1 Mar 2011 | 09:17 am

We all know that when writing multi-threaded programs one should remember about few more details like locking, using thread-safe libraries etc. Here is a list of not-so obvious bugs specific to multi-...

Using dd as a Swiss Army knife 13 Mar 2010 | 08:58 pm

Here are some useful examples of how a programmer (but not only) can use the dd command as a Swiss Army knife. Many of us are used to use a command similar to this one: This is a faster version of th...

Threads and fork(): think twice before mixing them. 9 Jun 2009 | 07:10 am

When debugging a program I came across a bug that was caused by using fork(2) in a multi-threaded program. I thought it's worth to write some words about mixing POSIX threads with fork(2) because ther...

Using Valgrind to debug memory leaks 20 Apr 2009 | 01:06 am

Valgrind is a wonderful tool useful mainly to debug memory related problems in C/C++ programs. I don't know a better tool to find memory leaks. Although output of this program is often clear and intui...

All about Linux signals 3 Feb 2009 | 11:33 am

In most cases if you want to handle a signal in your application you write a simple signal handler like: void handler (int sig) and use the signal(2) system function to run it when a signal is deliv...

C++ exception specifications are evil 21 Nov 2008 | 09:01 am

When I began to program in C++ I was already experienced in C and had written some code in Java. After writing few thousands lines of code in this language I felt comfortable with all of it's goodies ...

Pipe in bash can be a trap! 23 Oct 2008 | 04:18 am

Today a colleague at work tried to debug a script in bash that didn't want to work as he expected. He hit one of traps people get into when writing bash scripts. Let's look at the code that find the l...

LZMA - better than bzip2 21 Oct 2008 | 05:21 am

Everyone sometimes needs to compress something: doing backup, sending files over Internet etc. Most of us uses gzip or bzip2. It's known than bzip2 has a bit better compression ratio but it's much slo...

Related Keywords:

using valgrind to find memory leaks, programming blog, linux blog, using valgrind c, linux signals, sigaction example, c reference counting, what is a signal in programming?, programming blogs add your comment, linux programming blog 2011

Recently parsed news:

Recent searches: