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

Converting CVF into IVF - need your help

milan77
Beginner
338 Views

Dear IVF users,

I am porting my CVF standard console application into IVF environment.I was hoping to convert the project into a QuickWin application and to convert everything into free forms (approach 1). I simply created a newproject in IVF and copied my source code into new files and adjusted manually the formatting.As I have encountered some problems during the debug, I also did a direct transfer ofmy project into a CVF console application (keeping fixed forms)as described by S. Lionel in his March 17 document (approach 2).

I have not had any problems or errors reported with this project in CVF prior to conversion into IVF. In IVF, using the approach 2, the first error reported is "error LNK2019: unresolved external symbol _RUNQQ@16 referenced in function _REML". I include the "use ifport" in the REML (REML is not a function, but a subroutine). I use RUNQQ in this routine as:

res = RUNQQ(filelocation, command)

What does the "@16" in the error message mean? As I said, it was running fine in CVF. This is not causing any error message in the QuickWin (free form).

Second error appears during the execution of the following routine:

The routine starts:

SUBROUTINE sort(mating)

*** Common Declarations
USE FIXED_STORAGE
USE ALLOCATABLE_STORAGE

IMPLICIT NONE
*** Local Declarations:
INTEGER(kind=isingle),INTENT(IN) :: mating 
REAL(kind=rsingle),ALLOCATABLE,DIMENSION(:) :: aks
REAL(kind=rsingle),ALLOCATABLE,DIMENSION(:) :: arr
INTEGER(kind=idouble),ALLOCATABLE,DIMENSION(:) :: indx
INTEGER(kind=idouble) p,I,j,cnt,rn,IRANDOM

ALLOCATE(aks(NT(1)),arr(NT(1)),indx(NT(1)))
      
aks=0.
indx=0
arr=0.

I get the following error message during the debug:

"Unhandled exception at 0x0045f0a1 in name.exe: 0xC0000005: Access violation writing location 0x00000018." Severe(157) access violation.

There is an arrow pointing to the "aks=0." line. This problem happens in both console and QW applications.

I was speculating that this could be due to some default memory setting in IVF, but I am not an expert and always try to keep the default settings.

Could you, please, be so kind and provide me some advice on how to resolve this? Your help is very appreciated,

Milan

Intel Pentium M 1.7 GHz, 512 MB, MS Windows Prof SP1, Intel Fortran Compiler Integration for Microsoft Visual Studio .NET 2003, Version 8.0.1877.2003

0 Kudos
2 Replies
Steven_L_Intel1
Employee
338 Views
For the first problem, you can do one orboth of two things:
1) Remove the /iface:cvf (Default Calling Convention: CVF) from your project properties. You may not need it.
2) Download and install a more recent version of the compiler from Premier Support. My guess is that you are using the original December release 8.0.034.
For the second problem, I note that you did not check the status of the ALLOCATE to see if it succeeded. But this problem may also be fixed by installing a recent compiler.
0 Kudos
milan77
Beginner
338 Views
Thank you for your help, theupdate of Fortran resolved all issues mentioned above.
Iam alsoverypleased that the new compiler pointed atmy programming error -I have had adifficulty to figure out whatwaswrong under CVF and now theIVF resolved this problem.
Milan
0 Kudos
Reply