- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am converting a large system from HP Unix fortran to ifort on the PC. I was able to get the system to come up after adding the assume byterecl compiler option that I learned about here (thanks!). The system does direct io OPENS and CLOSES. It can OPEN files successfully, but every time it tries to CLOSE a file, I get the ACCESS Violation that I listed in the title. Here are my compile options;
-nologo \\
-c \\
-Qzero \\
-Qsave \\
-Qvc8 \\
-Od \\
-Z7 \\
-MD \\
-check:all \\
-warn:all \\
-warn:nodeclarations \\
-extend-source \\
-iface:default \\
-iface:nomixed_str_len_arg \\
-convert:big_endian \\
-assume:byterecl \\
-traceback \\
-fpe:0 \\
-fpscomp:logicals \\
-nopdbfile \\
-debug:full \\
-DUPPERCASE \\
-DWIN \\
-DWIN32X_9
I commented out some closes, and the internal debugger gave back results like
A103C RDM NFC= 44 ISTAT= 1633434201
and
A103C DIRECT_IO NFC= 22 ISTAT= 1280070990
where A103C is the close routine.
ISTAT is, I think, copied from IOSTAT.
Any suggestions would be greatly appreciated!
-nologo \\
-c \\
-Qzero \\
-Qsave \\
-Qvc8 \\
-Od \\
-Z7 \\
-MD \\
-check:all \\
-warn:all \\
-warn:nodeclarations \\
-extend-source \\
-iface:default \\
-iface:nomixed_str_len_arg \\
-convert:big_endian \\
-assume:byterecl \\
-traceback \\
-fpe:0 \\
-fpscomp:logicals \\
-nopdbfile \\
-debug:full \\
-DUPPERCASE \\
-DWIN \\
-DWIN32X_9
I commented out some closes, and the internal debugger gave back results like
A103C RDM NFC= 44 ISTAT= 1633434201
and
A103C DIRECT_IO NFC= 22 ISTAT= 1280070990
where A103C is the close routine.
ISTAT is, I think, copied from IOSTAT.
Any suggestions would be greatly appreciated!
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This post would fare better in the Fortran Compiler for Windows forum.
It is next to impossible to debug a large software program given no source code, not even a few lines suspected of causing problems, without knowing what OS, compiler version were used, when the traceback printout is not shown, ...
Re: "ISTAT is, I think, copied from IOSTAT" : quoting lines of code would be more useful than stating guesses.
It is next to impossible to debug a large software program given no source code, not even a few lines suspected of causing problems, without knowing what OS, compiler version were used, when the traceback printout is not shown, ...
Re: "ISTAT is, I think, copied from IOSTAT" : quoting lines of code would be more useful than stating guesses.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
So noted! I thought I was on the Windows forum, my apologies. I will repost there.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Are these input files or output files (or unknow as to if in/out/undefined)?
Are these files open on multiple IO units?
Insert some diagnostic code in front of close statement to perform INQUIRE...
Jim Dempsey
Are these files open on multiple IO units?
Insert some diagnostic code in front of close statement to perform INQUIRE...
[bash]LOGICAL :: I_OPENED, I_PENDING CHARACTER(1024) :: I_NAME CHARACTER(128) :: I_SHARE, I_WRITE ... INQUIRE (YourUnit, OPENED=I_OPENED, NAME=I_NAME, PENDING=I_PENDING, SHARE=I_SHARE, WRITE=I_WRITE) IF(I_OPENED) THEN WRITE(*,*) 'OPENED=',I_OPENED', NAME=',I_NAME WRITE(*,*) 'PENDING=', I_PENDING, ' SHARE=' I_SHARE' ', WRITE=' I_WRITE) ELSE WRITE(*,*) 'UNIT=',YourUnit, ' not open??' ENDIF CLOSE YourUnit ... [/bash]
Jim Dempsey

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page