Fortran RESHAPE in type declaration causes internal compiler error


Reference Number :  DPD200118682


Version :  10.1, 11.0


Operating System :  Windows*, Linux*, Mac OS X* / IA-32, Intel® 64, IA-64


Problem Description

Use of the Fortran Transformational Intrinsic Function RESHAPE in a type declaration statement with an shape mismatch between result array shape specification and actual result array causes an internal compiler error with the Intel Fortran compiler. The error occurs with a result array of any data type.

The compiler error issued as shown in the sample demonstration below includes an indication of the source line with the RESHAPE usage responsible for causing the internal error. Therefore, users receiving this internal error should immediately inspect the type declaration statement containing RESHAPE that is indicated in the error and change the shape specification for the result array to match the shape of the actual result array if equal shapes were intended.

Given the following sample.f90 source:

PROGRAM SAMPLE
! Non-equal shape of [1,5] specified for RESHAPE result array in type declaration
! causes internal compiler error. The correct shape specification is [2,5]

INTEGER :: AR1( 2, 5) = RESHAPE([1,2,3,4,5,6,7,8,9,10],[1,5],ORDER=[2,1])
!                                                       ^^^  non-equal shape
END
$ ifort -V -c sample.f90
Intel® Fortran Compiler Professional for applications running on Intel® 64, Version 11.0 Build 20090131 Package ID: l_cprof_p_11.0.081
Copyright (C) 1985-2009 Intel Corporation. All rights reserved.

Intel Fortran 11.0-1569
sample.f90(5): internal error: Please visit 'http://www.intel.com/software/products/support' for assistance.
INTEGER :: AR1( 2, 5) = RESHAPE([1,2,3,4,5,6,7,8,9,10],[1,5],ORDER=[2,1])
^
[ Aborting due to internal error. ]
compilation aborted for sample.f90 (code 1)


Resolution Status :  To avoid this error, correct the result array specification in the RESHAPE usage responsible for causing the error. This is a known issue that is resolved in the initial release of the Intel Fortran compiler 11.1 release (package ids: w_cprof_p_11.1.035 - Windows*, l_cprof_11.1.038 - Linux*, m_cprof_p_11.1.046 - Mac OS X*)



[DISCLAIMER: The information on this web site is intended for hardware system manufacturers and software developers. Intel does not warrant the accuracy, completeness or utility of any information on this site. Intel may make changes to the information or the site at any time without notice. Intel makes no commitment to update the information at this site. ALL INFORMATION PROVIDED ON THIS WEBSITE IS PROVIDED "as is" without any express, implied, or statutory warranty of any kind including but not limited to warranties of merchantability, non-infringement of intellectual property, or fitness for any particular purpose. Independent companies manufacture the third-party products that are mentioned on this site. Intel is not responsible for the quality or performance of third-party products and makes no representation or warranty regarding such products. The third-party supplier remains solely responsible for the design, manufacture, sale and functionality of its products. Intel and the Intel logo are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States and other countries. *Other names and brands may be claimed as the property of others.]
Nähere Informationen zur Compiler-Optimierung finden Sie in unserem Optimierungshinweis.