- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have a code to write a large array.
WRITE(EIN,'(1X,i8,2ES20.10)') (i,coord(i,:),i=1,nnode)
it stops at i=63800. Do you know why? Thanks a lot for your help in advance!
Link Copied
- « Previous
-
- 1
- 2
- Next »
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
>>I think the issue is that coord(i,:) creates a stack temp that is not removed on each iteration through the loop.
I presume that this is due to the newer generation of programmers (compiler writers) favoring recursive algorithms as opposed to iterative algorithms....
... the code passes simple tests.... but fails in the users hands.
Hmmm.... wouldn't it be ironic if the cause was old code contained a GOTO that could be removed by recursively calling the procedure....
;)
Jim Dempsey
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
No recursion here - just creation of a stack temp in a loop without cutting it back until the end of the statement.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Steve, your suggested solution works.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Glad to hear it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Has a bug report been filed?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Has a bug report been filed?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I submitted this as issue 04460165.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks Steve, I would have done that in no one had because that needs fixing IMO
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Intel bug ID is CMPLRIL0-32365
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
For windows add /link /stack:100000000 to the end of the ifort command works. However, for Linux, I can use command ulimit -s unlimited, before executing the code to resolve this issue. If I want to resolve it during compiling and linking, what command should I use?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I tried to compile using -heap-arrays option, a code runs for 6 seconds using ulimit -s unlimited now runs for 10 seconds.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Linux doesn't allow you to set this during the build (and Windows doesn't allow you to set it during execution.)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This bug got fixed a while ago - the program now completes normally with the 2021.4 compiler, but I don't know how far back the fix goes. The compiler now properly cuts back the stack on each iteration (the correct fix.)
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- « Previous
-
- 1
- 2
- Next »