Subject: [Announcement:] libefence Date: Thu, 15 Mar 2001 20:09:23 -0500 From: Igor Markov Organization: U. of Michigan, EECS Newsgroups: umich.eecs.class.380 I just noticed that CAEN Linux machines (e.g., red) have Electric Fence (efence) installed. This is a very neat debugging tool, and you could use it to find sneaky memory problems in your code. It is rarely finding anything that purify does not find, but I saw such cases. In addition, efence is free and comes with most Linux distributions. CAEN Linux systems should be able to compile/run your code just as well as Solaris systems, but you need to double check that your code runs on Solaris before you submit it. To use efence, you need to add -lefence at the end of the line in your Makefile that creates executables. This will cause your program run much slower and use a lot more memory, but the main effect is that if something is wrong with memory accesses (such as out-of-bounds array accesses or broken pointers), your program will seg. fault right away. Therefore, you need to run in gdb or ddd, and you will know where the problems are. The main advantage of using efence is that it exposes "hidden" bugs that silently wreak havok in your program and lead to unexplicable seg. faults later on (those are very hard to debug). AFAIK, you can't use efence and purify at the same time, but I haven't tried that with the latest versions. -- Igor Markov (734) 936-7829 EECS 2211 http://www.eecs.umich.edu/~imarkov