From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13854 invoked by alias); 29 Jan 2011 13:53:14 -0000 Received: (qmail 13842 invoked by uid 22791); 29 Jan 2011 13:53:13 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 29 Jan 2011 13:53:07 +0000 From: "dominiq at lps dot ens.fr" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/47042] ICE with character pointer in function X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: dominiq at lps dot ens.fr X-Bugzilla-Status: NEW X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Status Last reconfirmed Ever Confirmed Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Date: Sat, 29 Jan 2011 16:16:00 -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 X-SW-Source: 2011-01/txt/msg03228.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47042 Dominique d'Humieres changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2011.01.29 13:53:01 Ever Confirmed|0 |1 --- Comment #1 from Dominique d'Humieres 2011-01-29 13:53:01 UTC --- I confirm the ICE on *-apple-darwin* on trunk: pr47042.f90: In function 'get_cstring': pr47042.f90:9:0: internal compiler error: in build_function_decl, at fortran/trans-decl.c:1683 The code in comment #0 compiles with gfortran 4.5 (4.5.0 and 4.5.2 r167027) and 4.4.4, but fails to link because c_f_pointer is not found. So it looks like a regression. However if I remove the ONLY clause, I get an ICE with the versions I have tested: 4.6) gimplification failed: ptmp QI size unit size align 8 symtab 0 alias set -1 canonical type 0x141e02b28 attributes value >> arg-types chain chain >>> pointer_to_this > unsigned DI size unit size align 64 symtab 0 alias set -1 canonical type 0x141e02d20> constant arg 0 addressable static QI file pr47042_db_4.f90 line 6 col 0 align 8 context result ignored VOID file pr47042_db_4.f90 line 6 col 0 align 8 context >> pr47042_db_4.f90:6:0> pr47042_db_4.f90: In function 'get_cstring': pr47042_db_4.f90:6:0: internal compiler error: gimplification failed 4.5) pr47042_db_4.f90: In function 'get_cstring': pr47042_db_4.f90:10:0: internal compiler error: in gimplify_expr, at gimplify.c:7362 4.4) pr47042_db_4.f90: In function 'get_cstring': pr47042_db_4.f90:2: internal compiler error: in fold_convert, at fold-const.c:2654 So for the time being, I refrain to mark this pr as a regression. The backtrace for 4.6 is #0 fancy_abort (file=0x1009d44c8 "../../work/gcc/fortran/trans-decl.c", line=1683, function=0x100a46c00 "build_function_decl") at ../../work/gcc/diagnostic.c:893 #1 0x00000001000c8326 in build_function_decl (sym=0x141c17410, global=0 '\0') at ../../work/gcc/fortran/trans-decl.c:1680