Not sure who upstream maintainer for Boehm GC is, so reporting this here. I'm experiencing repeatable memory corruption with Boehm GC 6.2r1 in my C++ application. Gdb watchpoint confirms that Boehm GC is replacing a GC_malloc'd pointer with an invalid address that then causes a SEGV later on. Application runs correctly when not linked against libgc (and valgrind reports no errors). I'm happy to try to help diagnose this but I'm not sure how to proceed - please let me know what futher information is needed. -- jeek
I've just committed the latest snapshot of boehm-gc, 6.3-alpha5. If that doesn't solve the problem, please report it to gc@linux.hpl.hp.com. See http://www.hpl.hp.com/personal/Hans_Boehm/gc/ for how to subscribe the list.
I've discovered that the problem was provoked by allocating a particular object from the regular C++ heap rather than from the garbage collected pool. Changing this particlar allocations causes the corruption to go away. I suspect it's still a bug though as I expect to be able to mix allocations from regular g++ new and Boehm GC_malloc in the same process. -- jeek
Oops - didn't spot your suggestion to upgrade - will check out the new version and let you know. Thanks, -- jeek
Please take it to upstream if the problem still persists with boehm-gc-6.4.