<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Look up these options in your in Intel® Fortran Compiler</title>
    <link>https://community.intel.com/t5/Intel-Fortran-Compiler/FORTRAN-code-is-linking-even-with-SUBROUTINE-CALL-parameter/m-p/1174621#M146963</link>
    <description>&lt;P&gt;Look up these options in your compiler documentation:&amp;nbsp;&lt;STRONG&gt;/gen_interfaces&amp;nbsp;&lt;/STRONG&gt;and &lt;STRONG&gt;/warn:interfaces&amp;nbsp;&lt;/STRONG&gt;. There are corresponding settings in the Visual Studio IDE.&lt;/P&gt;</description>
    <pubDate>Fri, 04 Oct 2019 06:08:07 GMT</pubDate>
    <dc:creator>mecej4</dc:creator>
    <dc:date>2019-10-04T06:08:07Z</dc:date>
    <item>
      <title>FORTRAN code is linking even with SUBROUTINE/CALL parameter mismatch</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/FORTRAN-code-is-linking-even-with-SUBROUTINE-CALL-parameter/m-p/1174618#M146960</link>
      <description>&lt;P&gt;Recently I was working with some legacy FORTRAN code (after a long time)&amp;nbsp;to compile and generate 64bit binaries. There was a mistake in the code in which parameters used (number of parameters) in SUBROUTINE and corresponding CALL were not matching as illustrated below.&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; SUBROUTINE ABCD(NEQ,MA,NBLOCK,NEQB,NWA,MI,NSTIF,NRED,NL,&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;* &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; NR,AC,DM,DC,GAMA,AKEFFC,XNDIS,NUMIMD,&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;$ &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; XNACC,NUMIMA,STFSPG,NUMSPG,XNSPG)&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;CALL ABCD(N,MBW,NBLOCK,NEQB,NAV,MI,L14,L17,L13,L12,AC)&lt;/P&gt;&lt;P&gt;To my surprise I did not notice the error until linking failure occured&amp;nbsp;when I tried to create 32 bit binaries. The linker is not complaining and producing the final application binary without any error when I create 64 bit binaries!&lt;/P&gt;&lt;P&gt;Is this behavior expected? BTW, I am using Visual Studio 2017 Version 15.9.14 &amp;amp; Intel® Parallel Studio XE 2019 Update 4 Composer Edition for Fortran.&lt;/P&gt;</description>
      <pubDate>Fri, 04 Oct 2019 02:17:44 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/FORTRAN-code-is-linking-even-with-SUBROUTINE-CALL-parameter/m-p/1174618#M146960</guid>
      <dc:creator>Sudip_Chakraborty</dc:creator>
      <dc:date>2019-10-04T02:17:44Z</dc:date>
    </item>
    <item>
      <title>Yes, this is expected</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/FORTRAN-code-is-linking-even-with-SUBROUTINE-CALL-parameter/m-p/1174619#M146961</link>
      <description>&lt;P&gt;Yes, this is expected behavior with 32 and 64 bit compilations with the Intel compiler with the default subprogram calling convention. You may have used in the past a compiler (MS Fortran, Digital/Compaq Fortran) that decorated the names with @nn, with nn being the bytes taken by the subprogram arguments.&amp;nbsp;&lt;/P&gt;&lt;P&gt;There are compiler options available to check interfaces that you can use to catch this kind of error. Or, you can put subprograms into modules and USE those modules, in which case interface checking is done at compile time without needing any special option. You may also use internal subprograms.&lt;/P&gt;</description>
      <pubDate>Fri, 04 Oct 2019 04:43:59 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/FORTRAN-code-is-linking-even-with-SUBROUTINE-CALL-parameter/m-p/1174619#M146961</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2019-10-04T04:43:59Z</dc:date>
    </item>
    <item>
      <title>Thanks for the clarification.</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/FORTRAN-code-is-linking-even-with-SUBROUTINE-CALL-parameter/m-p/1174620#M146962</link>
      <description>&lt;P&gt;Thanks for the clarification. Can you please elaborate on the available compiler option to flag this error during compile time? Which option should I turn on?&lt;/P&gt;</description>
      <pubDate>Fri, 04 Oct 2019 05:39:01 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/FORTRAN-code-is-linking-even-with-SUBROUTINE-CALL-parameter/m-p/1174620#M146962</guid>
      <dc:creator>Sudip_Chakraborty</dc:creator>
      <dc:date>2019-10-04T05:39:01Z</dc:date>
    </item>
    <item>
      <title>Look up these options in your</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/FORTRAN-code-is-linking-even-with-SUBROUTINE-CALL-parameter/m-p/1174621#M146963</link>
      <description>&lt;P&gt;Look up these options in your compiler documentation:&amp;nbsp;&lt;STRONG&gt;/gen_interfaces&amp;nbsp;&lt;/STRONG&gt;and &lt;STRONG&gt;/warn:interfaces&amp;nbsp;&lt;/STRONG&gt;. There are corresponding settings in the Visual Studio IDE.&lt;/P&gt;</description>
      <pubDate>Fri, 04 Oct 2019 06:08:07 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/FORTRAN-code-is-linking-even-with-SUBROUTINE-CALL-parameter/m-p/1174621#M146963</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2019-10-04T06:08:07Z</dc:date>
    </item>
  </channel>
</rss>

