PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

Free OpenACC Webinar

C_LOC in an array constructor causes internal compiler error

 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling
View previous topic :: View next topic  
Author Message
Breitenfeld



Joined: 07 Jul 2008
Posts: 10

PostPosted: Tue Aug 30, 2011 1:16 pm    Post subject: C_LOC in an array constructor causes internal compiler error Reply with quote

When compiling the code:

use iso_c_binding

INTEGER(C_INT), DIMENSION(1:1), TARGET :: A = (/1/)
INTEGER(C_INT), DIMENSION(1:1), TARGET :: B = (/2/)
TYPE(C_PTR), DIMENSION(1:1,1:2), TARGET :: wdata2D

wdata2D(1,1) = C_LOC(A(1))
wdata2D(1,2) = C_LOC(B(1))

! remove this line and it compiles fine
wdata2D(1,1:2) = (/C_LOC(A(1)), C_LOC(B(1))/)

end

Produces the error:

Lowering Error: unknown target type for conversion [ast=97,asttype=7,datatype=56]
Lowering Error: target type was 56
PGF90-F-0000-Internal compiler error. Errors in Lowering 2 (test3.f90: 12)
PGF90/x86 Linux 11.7-0: compilation aborted
Back to top
View user's profile
jtull



Joined: 30 Jun 2004
Posts: 445

PostPosted: Tue Aug 30, 2011 1:59 pm    Post subject: Compilation with ISO_C_BINDING fails Reply with quote

I have replicated this problem and logged itas TPR 18144

I have asked for a workaround from engineering.

thanks,
dave
Back to top
View user's profile
jtull



Joined: 30 Jun 2004
Posts: 445

PostPosted: Wed May 22, 2013 10:53 am    Post subject: TPR 18144 is fixed as of 13.1 Reply with quote

We have fixed the your reported problem.

TPR 18144 - ISO_C_BINDING problem gets ICE 'unknown target type for conversion'

thanks for the report.

dave
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling All times are GMT - 7 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © phpBB Group