Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

stdout, unit 6, and 64bit

Lars_Jakobsen
Beginner
537 Views

Hi all,

We are in the process of porting our code from 32bit to 64bit.

This code has unit 6 attached to an output file (file on disk) and uses write(6,*) when writing to the output file and write(*,*) when writing to the screen. This works well in 32bit. In 64 bit however, write(*,*) is written both to the file and the screen (write(6,*) still only writes to the output file).

This program is originally ported from VMS and has the /VMS option set to yes. I have been told that this is why it has been working so far in 32bit - is this true?

Is there a way to get this to work in 64bit?

I am using "Intel(R) Visual Fortran Compiler XE 14.0.3.202 [Intel(R) 64]"

Regards

Lars

 

 

0 Kudos
1 Solution
Steven_L_Intel1
Employee
537 Views

Most likely is that you set an option for the Win32 configuration but not for the x64 configuration. Check the project properties. The option that controls this is /assume:[no]old_unit_star. The default is old_unit_star, which separates unit * from units 5/6.

/vms has nothing to do with 32-bit vs. 64-bit and I don't think /vms affects this behavior. But /standard-semantics does (Language > Assume Fortran 2003 semantics)

View solution in original post

0 Kudos
3 Replies
andrew_4619
Honored Contributor II
537 Views

I noted from help that:

  • Implied logical unit numbers

    The vms option enables Intel® Fortran to recognize certain environment variables at run time for ACCEPT, PRINT, and TYPE statements and for READ and WRITE statements that do not specify a unit number (such as READ (*,1000)).

So perhaps the 32 bit and 64 bit environments are different?

Why do you need the vms option?

0 Kudos
Steven_L_Intel1
Employee
538 Views

Most likely is that you set an option for the Win32 configuration but not for the x64 configuration. Check the project properties. The option that controls this is /assume:[no]old_unit_star. The default is old_unit_star, which separates unit * from units 5/6.

/vms has nothing to do with 32-bit vs. 64-bit and I don't think /vms affects this behavior. But /standard-semantics does (Language > Assume Fortran 2003 semantics)

0 Kudos
Lars_Jakobsen
Beginner
537 Views

Thank you both

You are right my settings was different. The culprint was the /standard-semantics (F2003Semantics="true").

Regards
 

Lars

 

0 Kudos
Reply