srikanthnz
Programmer
Hi all,
I know this question has been asked before and I confess I didn't spend enough time searching for an answer.
Here is what I want to do:
Program Main
--------------
--------------
do i = 1, N
CALL UPDATE
end do
--------------
--------------
End Program Main
Subroutine UPDATE
-----------------
------------------
Allocate(head(mxmy))
--------------
--------------
Allocate(list(NxNy))
--------------
--------------
Deallocate(head,list)
end subroutine update
Where the arrays are declared in a separate module
module link
implicit none
integer, allocatable :: head),list)
end module link
I compile the program with necessary modules and when I try to execute it I get this following error
exe: 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.
When I traced for the source of error, it looks like the execution is halted near the second allocate statement.
Cheers
Srikanth
I know this question has been asked before and I confess I didn't spend enough time searching for an answer.
Here is what I want to do:
Program Main
--------------
--------------
do i = 1, N
CALL UPDATE
end do
--------------
--------------
End Program Main
Subroutine UPDATE
-----------------
------------------
Allocate(head(mxmy))
--------------
--------------
Allocate(list(NxNy))
--------------
--------------
Deallocate(head,list)
end subroutine update
Where the arrays are declared in a separate module
module link
implicit none
integer, allocatable :: head),list)
end module link
I compile the program with necessary modules and when I try to execute it I get this following error
exe: 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.
When I traced for the source of error, it looks like the execution is halted near the second allocate statement.
Cheers
Srikanth