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

Catastrophic error during compilation involving pointer functions

Ned
Beginner
401 Views
Attached is a program that reproduces the error.

If one uncomments the line using the associated name (right before the problematic line, there is another error complaining about that the associate name cannot be a pointer.

Any help is appreciated. Thanks!

Regards,
Ned
0 Kudos
5 Replies
TimP
Honored Contributor III
401 Views
I'm surprised the compiler doesn't complain about options -O5 and the like. Nevertheless, this surely looks like a reportable bug.
0 Kudos
Kevin_D_Intel
Employee
401 Views

This internal error looks to be the same reported in your earlier thread (here) for type1_type.f90. I'll inquire about the errors requiring POINTER attribute/cannot be a pointer. Stay tuned....
0 Kudos
Ned
Beginner
401 Views

This internal error looks to be the same reported in your earlier thread (here) for type1_type.f90. I'll inquire about the errors requiring POINTER attribute/cannot be a pointer. Stay tuned....
bump -- any news?
0 Kudos
Kevin_D_Intel
Employee
401 Views
Quoting - Ned
bump -- any news?

My apologies for not coming back here. I've been updating status of associated internal tracking ids in your earlier thread (here).

I don't have new info about errors (#6793 - POINTER attribute required and #8201 - Associate name cannot be pointer). Will ping.

The internal error from this thread involving type1_type.f90 (see below) is related to report from the earlier thread (DPD200139961 - internal error in type1_type.f90).

The issue will be fixed in the upcoming Update 4 that's due out in a few days. I will update both threads once the update is available.


ifort -c -DDP -r8 -V -fpp -O5 -pad -Vaxlib -w -axW -automatic -cxxlib -I./ -I/tmp/codes/tests/ifortPointer2/src/mod -I/tmp/codes/tests/ifortPointer2/src/mod/utils -I/tmp/codes/tests/ifortPointer2/thirdParty/cgnslib_2.5/include -I/tmp/codes/tests/ifortPointer2/src/cgnsIO -I/tmp/codes/tests/ifortPointer2/src -I/tmp/codes/tests/ifortPointer2/mod/linuxIntelDPOpt
-module /tmp/codes/tests/ifortPointer2/mod/linuxIntelDPOpt -o /tmp/codes/tests/ifortPointer2/src/obj/linuxIntelDPOpt/./type1_type.o type1_type.f90
Intel Fortran Intel 64 Compiler Professional for applications running on Intel 64, Version 11.1 Build 20091012 Package ID: l_cprof_p_11.1.059
Copyright (C) 1985-2009 Intel Corporation. All rights reserved.

Intel Fortran 11.1-2620
type1_type.f90(27): catastrophic error: **Internal compiler error: internal abort** Please report this error along with the circumstances in which it occurred in a Software Problem Report. Note: File and line given may not be explicit cause of this error.
this% type2Ptr => Extended2_new()
-------------------------------^
compilation aborted for type1_type.f90 (code 3)
0 Kudos
Kevin_D_Intel
Employee
402 Views

I don't have new info about errors (#6793 - POINTER attribute required and #8201 - Associate name cannot be pointer). Will ping (DPD200148462).

The internal error from this thread involving type1_type.f90 is related to report from the earlier thread (DPD200139961 - internal error in type1_type.f90).


Theinternal error from this thread that is related to theearlier reported defect DPD200139961 is fixed in the Intel Fortran Compiler Professional Edition 11.1 Update 4 (11.1.064 - Linux).

Development provided the following summary regarding errors (#6793 - POINTER attribute required and #8201 - Associate name cannot be pointer):

This is a misunderstanding of Fortran 2003 standard.

The construct:

a=> Extended2_new()

is a pointer assignment, which is specified by Fortran 2003 standard, section 7.4.2 as follows:

R735 pointer-assignment-stmt is data-pointer-object [ (bounds-spec-list) ] => data-target
or data-pointer-object (bounds-remapping-list ) => data-target
or proc-pointer-object => proc-target

The left side of the pointer assignment (data-pointer-object) must be a variable:

C721 (R736) A variable-name shall have the POINTER attribute.

On the other hand, name defined in ASSOCIATE or SELECT TYPE statement is a construct entity (section 16.4.1.5):

Execution of a SELECT TYPE statement establishes an association between the selector and the associate name of the construct. Execution of an ASSOCIATE statement establishes an association between each selector and the corresponding associate name of the construct.

Such entities cannot have POINTER attribute (section 16.4.1.5):

If the selector has the POINTER attribute, it shall be associated; the associate name is associated with the target of the pointer and does not have the POINTER attribute.

So, the code is syntactically incorrect and compiler issues relevant diagnostics.
0 Kudos
Reply