Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Allocation Error

janos
Beginner
495 Views

Hello,

I've created a program with Intel Fortran Compiler 11.1 using openSUSE 11.2 and get such a mistake:

malloc.c:3096: sYSMALLOc: Assertion `(old_top == (((mbinptr) (((char *) &((av)->bins[((1) - 1) * 2])) - __builtin_offsetof (struct malloc_chunk, fd)))) && old_size == 0) || ((unsigned long) (old_size) >= (unsigned long)((((__builtin_offsetof (struct malloc_chunk, fd_nextsize))+((2 * (sizeof(size_t))) - 1)) & ~((2 * (sizeof(size_t))) - 1))) && ((old_top)->size & 0x1) && ((unsigned long)old_end & pagemask) == 0)' failed.
Abgebrochen

I'm using this command line to compile the program:

ifort *.f90 -g -traceback -o bem_kontakt

Normally I get the line inside the program where I could find the mistake.

I've tested the program. The main program is callig a subroutine twice. The first call works well, but the error occurs during the second call of the program.

How can I find such a mistake.

Thanks in advance

janos

0 Kudos
2 Replies
Stephen_D_Intel
Employee
495 Views

Hi janos,

You can try running in a debugger with breakpoints set for symbols like 'abort' and 'exit'. You may have to

experiment to get the right symbol. When you program hits the breakpoint, you should be able to get a

stack trace to see where the call to malloc came from in your program.

Regards,
Steve D.
Intel Developer Support

0 Kudos
Ron_Green
Moderator
495 Views

Another comment: OpenSUSE 11.2 is too new to be supported. We do not test on this OS, so it is possible that the traceback, which relies on the system's gcc and libc, may not work correctly. Is it possible to try this program on an older OpenSUSE?

ron

0 Kudos
Reply