libgc crash

We are getting a core dump on our application. The core stack shows:

(dbx) where -q

current thread: t@1

=>[1] __sigprocmask()

[2] _resetsig()

[3] _sigon()

[4] _thrp_kill()

[5] raise()

[6] abort()

[7] gcDefaultAbort()

[8] gcInternalAbort()

[9] gcGetCleanMemory()

[10] gcExpandHeapInner()

[11] gcCollectOrExpand()

[12] gcAllocobj()

[13] gcGenericMallocInner()

[14] gcGenericMalloc()

[15] malloc()

[16] operator new(unsigned)

............................................

...........................................

The versions are:

version libgc.so

version of "libgc.so":Sun C++ 5.5 2003/03/12

CC -V

CC: Sun C++ 5.5 2003/03/12

uname -a

SunOS cmrdev1 5.8 Generic_117350-27 sun4u sparc SUNW,Sun-Fire-880

There is plenty of memory on the system,and the process had lot of room to grow when it crashed.

The executable was built by adding -lgc to the link line.

What could be the reason?

Thanks.

[1099 byte] By [Guru_Chandar] at [2007-11-26 8:21:19]
# 1

The crash might be due to any of the reasons that cause a memory allocator to crash:

- use of an invalid or uninitialized pointer

- deleting an object more than once

- deleting a pointer value that was not obtained from the allocator

- using an object after it has been deleted or gone out of scope

- failure to guard the use of shared data in a multi-threaded program

Does the program crash if you don't link it with libgc? If not, perhaps the problem is a bug in libgc. We would need a test case that demonstrates the problem to determine whether that is the case.

You are using an old, unpatched compiler. Another possible cause is a bug in the compiler or one of its runtime libraries. Try installing all of the latest patches, which you can get here:

http://developers.sun.com/prodtech/cc/downloads/patches/index.jsp

If possible, I suggest upgrading to Sun Studio 11, which is free. You can get it here:

http://developers.sun.com/sunstudio/

clamage45 at 2007-7-6 21:27:44 > top of Java-index,Development Tools,Solaris and Linux Development Tools...