On Fri, 2012-06-01 at 16:07 -0400, Jerry Feldman wrote:
I've seen this before. There is a lot of code that gets executed before the actual main() function. I don't think this has to do with the kernel, but possibly the loader. ElectricFence is also a good tool. One of the things that is normally done before main is memory allocation. Some times, libraries need to allocate some memory. Also, remember that Purify likes to tram mmap(2).
But is any code in a library actually called when it is loaded? I know on Windows there is code called then a DLL is loaded, reloaded or unloaded, and that the DLL maker has access to these hooks. Is there such code in a Linux DSO? I thought that all that happened was that symbols were resolved. Any memory allocated must be something determined by the linker when the library was made (library static data storage). Surely that allocation code is not failing Purify... My problem with ElectricFence is that I never have enough memory to let it run. And, it seems that it does not use swap. I added 8 GB of additional swap and set all my limits to unlimited. But the swap is never used when EF exits complaining it cannot get enough memory. My application has many small (and big) memory allocations. And the way EF works, that translates to lots of memory needed... Yours sincerely, Roger Oberholtzer OPQ Systems / Ramböll RST Office: Int +46 10-615 60 20 Mobile: Int +46 70-815 1696 roger.oberholtzer@ramboll.se ________________________________________ Ramböll Sverige AB Krukmakargatan 21 P.O. Box 17009 SE-104 62 Stockholm, Sweden www.rambollrst.se -- To unsubscribe, e-mail: opensuse-programming+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-programming+owner@opensuse.org