Re: Stack corruption and memory leak problems in c++/Fortran application
- From: Louis Krupp <lkrupp@xxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 31 Oct 2007 15:07:31 -0600
Anndy wrote:
On Oct 31, 3:31 pm, glen herrmannsfeldt <g...@xxxxxxxxxxxxxxxx> wrote:Anndy wrote:On Oct 31, 12:47 pm, "Colin Watters"It could just be that the stack is too small.
<qolin.see_signat...@xxxxxxxxxxxxx> wrote:
"Anndy" <see.n...@xxxxxxxxx> wroteI am facing problem in a Porting project(HP-Unix->Windows XP(64 bit))
where there are lots of C++->Fortran and Fortran->C++ calls.
There are some thousands of files including FORTRAN and C++ code.
After performing few operation which involves lot of FORTRAN->C++ and C
++->FORTRAN calling, application gives stack overflow error or behaves
unexpectedly.
I tried with increasing the stack size in compiler options, but
problem remains the same.
You mean 4 bytes each call, that doesn't go away when it returns?one more thing which i have noticed is, whenever i am making a call to
a FORTRAN function there is a increase in
application memory by 4Bytes.
In other words, a memory leak?
Yes, This same thing I tried by creating a small application where i
am calling
a fortran subroutine from C++. In this sample I have not written any
code and subroutine
takes no argument. Here also i am seeing this leak.
Can you post the code in your small application?
If you have a memory leak and your subroutine has no arguments, then my theory about strlen() is indeed complete nonsense.
Louis
.
- References:
- Stack corruption and memory leak problems in c++/Fortran application
- From: Anndy
- Re: Stack corruption and memory leak problems in c++/Fortran application
- From: Colin Watters
- Re: Stack corruption and memory leak problems in c++/Fortran application
- From: Anndy
- Re: Stack corruption and memory leak problems in c++/Fortran application
- From: glen herrmannsfeldt
- Re: Stack corruption and memory leak problems in c++/Fortran application
- From: Anndy
- Stack corruption and memory leak problems in c++/Fortran application
- Prev by Date: Re: Stack corruption and memory leak problems in c++/Fortran application
- Next by Date: Re: IDE for Linux for C/C++ & Fortran
- Previous by thread: Re: Stack corruption and memory leak problems in c++/Fortran application
- Next by thread: Re: Stack corruption and memory leak problems in c++/Fortran application
- Index(es):
Relevant Pages
|