This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Fortran, Patch, pr65795, v1] Segfault (invalid write) for ALLOCATE statement involving COARRAYS


> On Apr 3, 2016, at 3:04 PM, Andre Vehreschild <vehre@gmx.de> wrote:
> 
> Hi Damian,
> 
> To say it quite bluntly, I don't know. I took care of the ICE only, but I don't have a deeper understanding of the coarray usage, therefore I can't answer your question.

Hi Andre,

No problem.  Thanks for the quick reply.

> What should the meaning of the line in question be? Doesn't it overwrite the allocated reference with the one of image 1? And how would you expect to continue from there?

Itâs just a check to see what the compiler will do.  It could be thought of as a poorly written broadcast.  To be a correct broadcast, it would require a âsync allâ just after the first assignment. Then the second assignment would give every image a copy of the caf component that was on image 1, which has an x component with the value 1.   Even with this correction, it would of course exhibit poor scaling due to network contention and it would be better to call co_broadcast.  

I just wrote it to see if there had been additional progress toward supporting derived type coarrays with allocatable or pointer components.  If so, that will be of great interest to the users of OpenCoarrays and I would announce it on the OpenCoarrays mailing list.

Damian



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]