- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Thanks,
David
forrtl: severe (170): Program Exception - stack overflow
Image PC Routine Line Source
testbayer.exe 0051D4C7 Unknown Unknown Unknown
testbayer.exe 004C1266 _MAIN__ 261 testdll.for
testbayer.exe 0057CAA3 Unknown Unknown Unknown
testbayer.exe 0051DB53 Unknown Unknown Unknown
testbayer.exe 0051D91D Unknown Unknown Unknown
kernel32.dll 7C816FD7 Unknown Unknown Unknown
Break on winsig.c line 419:
_VALIDATE_RETURN(("Invalid signal or error", 0), EINVAL, SIG_ERR);
/* should never happen, but compiler can't tell */
링크가 복사됨
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
testbayer.exe 004C1266 _MAIN__ 261 testdll.for
Last known code of yours is line 261 in the main program.
Judging from the source file name, it's a call to a dll routine? Since the call stack does not include any dll code, it's plausible that you got the calling sequence wrong, as you suspected.
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Last known code of yours is line 261 in the main program.
Judging from the source file name, it's a call to a dll routine? Since the call stack does not include any dll code, it's plausible that you got the calling sequence wrong, as you suspected.
Yes, I was trying to test a DLL. However, I have now added the source files to my project, so that I have
testdll.for - main program
bayervb.f90 - visual basic interface routine with DLL EXPORT directives
bayer.for - main calculation routine, which is called by bayervb when called from Excel, but called directly from testdll in this implementation.
Excel version works perfectly. I can't get this fortran stand-alone version to work. I can't work out why the break occurs in the winsig.c routine, which is presumably part of IVF.
Thanks
David
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Most likely you have an automatic array that gets stack allocated by default, and you've overflowed the default 1MB stack. Presumably, Excel is built with a larger stack. You can build your EXE with a larger stack (Linker > System > Stack Reserve Size) or use Heap Arrays: 0 to have these arrays allocated dynamically.
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Dear Steve,
I have the same problem with my code. I have some variables which are dynamically allocatated. They are shared by different subroutines using modules.
The program works perfect for small problems. However, as I changes the size of problem, which consequently increased the memory requirements by the variables.
I was trying to follow your advice give above, change the stack or heap reserve size, which is by defaut 0. I was wondering what values should be there?
I was looking for it but could not find it. Could you please tell me how the values should be specified, such in kb,MB or something else?
Waiting for your reply.
Regards,
Vinod
- 신규로 표시
- 북마크
- 구독
- 소거
- RSS 피드 구독
- 강조
- 인쇄
- 부적절한 컨텐트 신고
Breakpoint is trigerred inside winsig library which your code could have been linked to directly or indirectly.As Steve said the problem lies in stack overflow and it was solved in case of Vinod.
