Compiling with IVF 64bit

Hi,
For compiling 32&64bit version of products:

  1. I installed VS2005.
  2. I installed IVF 11.0.066 (32bit)
  3. I installed IVF 11.0.066 EM64T (64bit) on my machine.
    The 32 bit version works well in compiling and making adams.dll without any error.
    But 64 bit version is facing with following errors:

This is my CompileLinkA2AD.bat file content:
@ECHO OFF
SET MyCompiler=IVF
SET ROOT_NAME=ADAMS
SET IVF_LOC=“C:\Program Files (x86)\Intel\Compiler\11.0\066\fortran\Bin\intel64”
SET NWTC_Lib_Loc=C:\Design Codes\NWTC_Lib_v1.03.01\Source
SET AeroDyn_Loc=C:\Design Codes\AeroDyn\Source
SET Wind_Loc=C:\Design Codes\AeroDyn\Source\InflowWind\Source
SET FAST_Loc=C:\Design Codes\FAST\Source
SET A2AD_Loc=C:\Design Codes\A2AD\Source

REM -------------------- LIST OF ALL SOURCE FILES ------------------------------
REM -------- please note that all source files must have a blank line ----------
REM -------- at the end so that they can be concatenated properly ----------

SET NWTC_Files=
SET NWTC_Files=%NWTC_Files% “%NWTC_Lib_Loc%\SingPrec.f90”
SET NWTC_Files=%NWTC_Files% + “%NWTC_Lib_Loc%\SysIVF.f90”
SET NWTC_Files=%NWTC_Files% + “%NWTC_Lib_Loc%\NWTC_IO.f90”
SET NWTC_Files=%NWTC_Files% + “%NWTC_Lib_Loc%\NWTC_Num.f90”
SET NWTC_Files=%NWTC_Files% + “%NWTC_Lib_Loc%\NWTC_Aero.f90”
SET NWTC_Files=%NWTC_Files% + “%NWTC_Lib_Loc%\NWTC_Library.f90”

SET Wind_Files=
SET Wind_Files=%Wind_Files% “%Wind_Loc%\SharedInflowDefs.f90”
SET Wind_Files=%Wind_Files% + “%Wind_Loc%\HHWind.f90”
SET Wind_Files=%Wind_Files% + “%Wind_Loc%\FFWind.f90”
SET Wind_Files=%Wind_Files% + “%Wind_Loc%\FDWind.f90”
SET Wind_Files=%Wind_Files% + “%Wind_Loc%\CTWind.f90”
SET Wind_Files=%Wind_Files% + “%Wind_Loc%\UserWind.f90”
SET Wind_Files=%Wind_Files% + “%Wind_Loc%\InflowWindMod.f90”

SET AeroDyn_Files=
SET AeroDyn_Files=%AeroDyn_Files% “%AeroDyn_Loc%\SharedTypes.f90”
SET AeroDyn_Files=%AeroDyn_Files% + “%AeroDyn_Loc%\AeroMods.f90”
SET AeroDyn_Files=%AeroDyn_Files% + “%AeroDyn_Loc%\GenSubs.f90”
SET AeroDyn_Files=%AeroDyn_Files% + “%AeroDyn_Loc%\AeroSubs.f90”
SET AeroDyn_Files=%AeroDyn_Files% + “%AeroDyn_Loc%\AeroDyn.f90”

SET Fixed_Files =
SET Fixed_Files=%Fixed_Files% “%FAST_Loc%\fftpack.f”

SET FAST_Files=
SET FAST_Files=%FAST_Files% “%FAST_Loc%\FFTMod.f90”
SET FAST_Files=%FAST_Files% + “%FAST_Loc%\HydroCalc.f90”
SET FAST_Files=%FAST_Files% + “%A2AD_Loc%\FAST_params.f90”

rem IF /I “%1”==“DLL” GOTO dllFiles

rem SET FAST_Files=%FAST_Files% + “%FAST_Loc%\UserSubs.f90”
rem SET FAST_Files=%FAST_Files% + “%FAST_Loc%\UserVSCont_KP.f90”
rem SET FAST_Files=%FAST_Files% + “%FAST_Loc%\PitchCntrl_ACH.f90”

rem GOTO endFASTfiles

rem :dllFiles
SET FAST_Files=%FAST_Files% + “%FAST_LOC%\UserSubs_forBladedDLL.f90”
SET FAST_Files=%FAST_Files% + “%FAST_LOC%\UserVSCont_KP_forBladedDLL.f90”
SET FAST_Files=%FAST_Files% + “%FAST_LOC%\BladedDLLInterface.f90”

REM NOTE: UserSubs_forBladedDLL.f90 is a copy of UserSubs.f90 with SUBROUTINES UserHSSBr() and UserYawCont() commented out
REM UserVSCont_KP_forBladedDLL.f90 is a copy of UserVSCont_KP.f90 with SUBROUTINE UserVSCont() commented out

rem :endFASTfiles

SET A2AD_Files=
SET A2AD_Files=%A2AD_Files% “%A2AD_Loc%\A2AD_Mod.f90”
SET A2AD_Files=%A2AD_Files% + “%A2AD_Loc%\Adams_subs.f90”

REM ----------------------------------------------------------------------------
REM ----------- Concatenate them into one file for free-format -----------------
REM ----------- Fortran and one file for fixed-format Fortran -----------------
REM ----------------------------------------------------------------------------

COPY %NWTC_Files% + %Wind_Files% + %AeroDyn_Files% + %FAST_Files% + %A2AD_Files% %ROOT_NAME%.f90
COPY %Fixed_Files% %Root_Name%.f

REM ----------------------------------------------------------------------------
REM --------------------- INTEL VISUAL FORTRAN ---------------------------------
REM --------------------- with MD Adams 2010 ---------------------------------
REM ----------------------------------------------------------------------------
ECHO.
ECHO Using Intel Visual Fortran
ECHO.

REM …
REM … set compiler internal variables …
REM …
IF “%INTEL_SHARED%”=="" CALL %IVF_LOC%…\ifortvars.bat intel64

REM …
REM … set compiler options …
REM …

SET COPTS= /c /O1 /automatic /MD /Gm /traceback /Qzero /Qsave /real_size:64 /assume:byterecl /Qdiag-disable:5268

REM …
REM … compile …
REM …

ECHO.
ECHO Compiling ADAMS2AD and AeroDyn routines to create ADAMS.obj:

CALL %IVF_LOC%\IFORT %COPTS% /object:%ROOT_NAME%.obj %ROOT_NAME%.f90

cALL %IVF_LOC%\IFORT %COPTS% /object:%ROOT_NAME%f.obj %ROOT_NAME%.f

REM …
REM … link with Adams …
REM …

ECHO Linking ADAMS2AD and AeroDyn routines with MD ADAMS 2010
CALL C:\MSC.Software\MD_Adams_x64\2010\common\mdi.bat cr-user n %ROOT_NAME%.obj %ROOT_NAME%f.obj -n %ROOT_NAME%.dll exit < NewLine.txt

REM ----------------------------------------------------------------------------
REM ------------------------- CLEAR MEMORY -------------------------------------
REM ------------- and delete all .mod and .obj files ---------------------------
REM ----------------------------------------------------------------------------
ECHO

DEL *.mod
DEL *.obj
pause
SET MyCompiler=
SET DF_LOC=
SET IVF_LOC=
SET ROOT_NAME=
SET COPTS=

SET NWTC_Files=
SET Wind_Files=
SET AeroDyn_Files=
SET FAST_Files=
SET A2AD_Files=
SET Fixed_Files=

SET NWTC_Lib_Loc=
SET Wind_Loc=
SET AeroDyn_Loc=
SET A2AD_Loc=
SET FAST_Loc=

It seems that the problem is in compiling the accumulated fortran file. But dont know why.

Any help to fix the problem will be appreciable.

Here are some pics may help to solve the problem.
111.png

Thanks,

It looks like the 64-bit compiler’s default is /real-size:64, which is incompatible with the SingPrec.f90 file. To be consistant, you must choose one of the following options

  1. compile in single precision: Use SingPrec.f90 and the /real-size:32 compiler option (which is the default option for the 32-bit compiler)
  2. compile in double precision: Use DoubPrec.f90 and the /real-size:64 compiler option

Thanks bonnie,
How can compile using SingPrec.f90 and how DoubPrec.f90 ???
Could u explain a little more?
I modified 64 to 32 as below but other errors appeared as pic.
SET COPTS= /c /O1 /automatic /MD /Gm /traceback /Qzero /Qsave /real_size:32 /assume:byterecl /Qdiag-disable:5268

Regards,
Many thanks,

In the NWTC Library, you must choose a source file that contains the PRECISION module, which is either SingPrec.f90 or DoubPrec.f90. The script you are running uses the Sing.Prec.f90 source file. If you want to change that, you replace the text “SingPrec.f90” with “DoubPrec.f90” in the batch file.

The new error you are getting looks like an issue with some 64-bit variable definitions in the BladedDLLInterface.f90 file, which was fixed in FAST v7.01.00a-bjj. You can download it from our website.