From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29290 invoked by alias); 22 Jan 2015 12:47:06 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 29226 invoked by uid 48); 22 Jan 2015 12:46:57 -0000 From: "burnus at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/63861] OpenACC coarray ICE (also with OpenMP?) Date: Thu, 22 Jan 2015 12:47:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: 5.0 X-Bugzilla-Keywords: openacc, openmp X-Bugzilla-Severity: normal X-Bugzilla-Who: burnus at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: keywords short_desc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2015-01/txt/msg02368.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63861 Tobias Burnus changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |openmp Summary|OpenACC coarray ICE |OpenACC coarray ICE (also | |with OpenMP?) --- Comment #2 from Tobias Burnus --- With the patch for PR64726 applied and the ACC CACHE commented, the program gets stuck (endless loop) for the code in gcc/testsuite/gfortran.dg/goacc/coarray.f95. It works, if one changes the scalar coarray into either an array coarray or into a noncoarray scalar. I think gfc_has_alloc_comps just needs to be updated to handle coarrays, which use an array descriptor but aren't true arrays. (I think GFC_TYPE_ARRAY_RANK(...) == 0 can be used to detect this, but that might not work for all array types.) I marked it as "OpenMP" as it is probably also possible to trigger this for some OpenMP code. Even though, I do not have a test case. Backtrace: #1 gfc_get_element_type (type=0x7ffff20f25e8) at ../../gcc/fortran/trans-types.c:1180 #2 0x0000000000742f85 in gfc_has_alloc_comps (type=, decl=) at ../../gcc/fortran/trans-openmp.c:193 #3 0x000000000099eb12 in gimplify_scan_omp_clauses (list_p=0x7ffff20f32a0, pre_p=pre_p@entry=0x7fffffffd918, region_type=region_type@entry=ORT_TARGET) at ../../gcc/gimplify.c:6062 #4 0x00000000009a07c8 in gimplify_omp_workshare (expr_p=expr_p@entry=0x7ffff20eb778, pre_p=pre_p@entry=0x7fffffffd918) at ../../gcc/gimplify.c:7307