missaligned arrays

missaligned arrays

I have an older code which I wish to compile that contains missaligned arrays.

Outside a call to a subroutine:  Y(3,6)

In the subroutine call statement: G(3,6,8)

Previous versions of Intel Fortran would permit this to pass, but since I upgraded to VF 2010  and just now converted the project, I receive error messages.  What flags can be set to permit this to pass as before?  Any suggestions?  I do not wish to go through the code and fix these issues.

Current command line options are:

/nologo /debug:full /Od /pad_source /f66 /warn:interfaces /module:"Debug\\" /object:"Debug\\" /Fd"Debug\vc100.pdb" /traceback /check:bounds /libs:static /threads /dbglibs /c

Thank you

6 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

It looks like warn:interfaces is the one which is blocking acceptance of the non-conformant code.

This is not "misaligned arrays". I am unclear as to what your code looks like and you haven't shown us the error message. I agree with Tim that it is likely generated interface checking is catching something not caught before, but I don't think you have explained the code well. Please show us some actual code for both the call and how it is declared in the subroutine (including declarations of all arguments on both sides.) Also show us the complete and exact text of the error message(s).

Retired 12/31/2016

Paul C.: Since you already know that your code has argument array rank mismatches, but works(-ed) correctly, turning off the warn:interfaces option is probably the thing to try.

If you pass Y(1,1), then it's ok for the ranks to mismatch.

The option mecej4 mentions is Fortran > Diagnostics > Check Routine Interfaces. But turning this off exposes you to other coding errors that will go undetected.

Retired 12/31/2016

Folks,

The "warn: interfaces" apparently was the culprit.  I know it exposes other issues, but this is legacy code.  I appreciate your help. I thought it was something simple, but sometimes you don't see what's in front of you.

Thank you all again,

Paul

Leave a Comment

Please sign in to add a comment. Not a member? Join today