public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/58586] New: ICE with derived type with a polymorphic allocatable component passed by value
@ 2013-09-30 21:57 vladimir.fuka at gmail dot com
  2013-10-01 21:13 ` [Bug fortran/58586] [OOP] " burnus at gcc dot gnu.org
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: vladimir.fuka at gmail dot com @ 2013-09-30 21:57 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="UTF-8", Size: 8294 bytes --]

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58586

            Bug ID: 58586
           Summary: ICE with derived type with a polymorphic allocatable
                    component passed by value
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: vladimir.fuka at gmail dot com

> gfortran -c ice3.f90
ice3.f90: In function ‘sub’:
ice3.f90:29:0: internal compiler error: Segmentation fault
    call add(b())
 ^
0x87dfdf crash_signal
        ../../gcc-4.8-20130425/gcc/toplev.c:332
0x5b19b0 structure_alloc_comps
        ../../gcc-4.8-20130425/gcc/fortran/trans-array.c:7440
0x5c97ca gfc_conv_procedure_call(gfc_se*, gfc_symbol*, gfc_actual_arglist*,
gfc_expr*, vec<tree_node*, va_gc, vl_embed>*)
        ../../gcc-4.8-20130425/gcc/fortran/trans-expr.c:4621
0x5ede84 gfc_trans_call(gfc_code*, bool, tree_node*, tree_node*, bool)
        ../../gcc-4.8-20130425/gcc/fortran/trans-stmt.c:406
0x5a7761 trans_code
        ../../gcc-4.8-20130425/gcc/fortran/trans.c:1500
0x5c4a02 gfc_generate_function_code(gfc_namespace*)
        ../../gcc-4.8-20130425/gcc/fortran/trans-decl.c:5397
0x568770 translate_all_program_units
        ../../gcc-4.8-20130425/gcc/fortran/parse.c:4474
0x568770 gfc_parse_file()
        ../../gcc-4.8-20130425/gcc/fortran/parse.c:4688
0x5a3a85 gfc_be_parse_file
        ../../gcc-4.8-20130425/gcc/fortran/f95-lang.c:189
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.

module mod

  type,abstract :: a
  end type

  type :: b
     class(a),allocatable :: a
  end type

  interface b
    module procedure b_init
  end interface

contains

  subroutine add(c)
    type(b),value :: c
  end subroutine

  function b_init() result(res)
    type(b) :: res
  end function

end module mod

subroutine  sub
   use mod

   call add(b())

end subroutine  sub
>From gcc-bugs-return-430853-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Sep 30 22:54:24 2013
Return-Path: <gcc-bugs-return-430853-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 26304 invoked by alias); 30 Sep 2013 22:54:23 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 26261 invoked by uid 48); 30 Sep 2013 22:54:20 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/58587] New: Bootstrap error with ada with -mcpu=power7
Date: Mon, 30 Sep 2013 22:54:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords: ice-on-valid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub 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: bug_id short_desc product version bug_status keywords bug_severity priority component assigned_to reporter cc
Message-ID: <bug-58587-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2013-09/txt/msg02093.txt.bz2
Content-length: 2271

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58587

            Bug ID: 58587
           Summary: Bootstrap error with ada with -mcpu=power7
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: jakub at gcc dot gnu.org
                CC: meissner at gcc dot gnu.org

Trying to bootstrap gcc (4.8-RH, but reproduced also with the trunk) with
a ppc64 compiler configured --with-cpu=power7 ICEs during stage1 while par.adb
is being compiled at -O0.
Reproduced even with a cross-compiler from x86_64-linux, will attach a tarball
with all the required files.

../gnat1 -I. -gnatwa -quiet -nostdinc -m64 -gnatpg -gnatwns -mtune=power7
-mcpu=power7 par.adb -o /tmp/par.s
par.adb: In function ‘Par’:
par.adb:1604:5: error: insn does not satisfy its constraints:
(insn 1505 719 1504 (set (reg:TI 77 0)
        (const_double -16 [0xfffffffffffffff0] 7 [0x7] 0 [0] 0 [0]))
par.adb:1509 721 {*vsx_movti_64bit}
     (nil))
+===========================GNAT BUG DETECTED==============================+
| 4.9.0 20130927 (experimental) (powerpc64-linux) GCC error:               |
| in extract_constrain_insn_cached, at recog.c:2076                        |
| Error detected around par.adb:1604:5                                     |
| Please submit a bug report; see http://gcc.gnu.org/bugs.html.            |
| Use a subject line meaningful to you and us to track the bug.            |
| Include the entire contents of this bug box in the report.               |
| Include the exact gcc or gnatmake command that you entered.              |
| Also include sources listed below in gnatchop format                     |
| (concatenated together with no headers between files).                   |
+==========================================================================+
>From gcc-bugs-return-430854-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Sep 30 22:57:04 2013
Return-Path: <gcc-bugs-return-430854-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 28145 invoked by alias); 30 Sep 2013 22:57:04 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 28104 invoked by uid 48); 30 Sep 2013 22:57:02 -0000
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/58587] Bootstrap error with ada with -mcpu=power7
Date: Mon, 30 Sep 2013 22:57:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords: ice-on-valid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: jakub 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: attachments.created
Message-ID: <bug-58587-4-ppChf6V5vq@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-58587-4@http.gcc.gnu.org/bugzilla/>
References: <bug-58587-4@http.gcc.gnu.org/bugzilla/>
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: 2013-09/txt/msg02094.txt.bz2
Content-length: 528

http://gcc.gnu.org/bugzilla/show_bug.cgi?idX587

--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 30941
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id0941&actioníit
pr58587.tar.bz2

I've tried to create a C small reproducer from scratch, but just using TImode
seems to work, reload decides to put the extra large constant into memory, and
similarly say:
typedef int TI __attribute__((mode (TI)));
void
foo (void)
{
  asm volatile ("" : : "v" (((TI) 0x7fffffffffffffffUL) << 4));
}


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2015-07-09 10:42 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-30 21:57 [Bug fortran/58586] New: ICE with derived type with a polymorphic allocatable component passed by value vladimir.fuka at gmail dot com
2013-10-01 21:13 ` [Bug fortran/58586] [OOP] " burnus at gcc dot gnu.org
2014-01-05 12:34 ` dominiq at lps dot ens.fr
2014-01-05 13:53 ` [Bug fortran/58586] ICE with derived type with " janus at gcc dot gnu.org
2014-01-05 14:00 ` janus at gcc dot gnu.org
2015-04-15 18:04 ` vehre at gcc dot gnu.org
2015-05-11  9:08 ` dominiq at lps dot ens.fr
2015-05-11 10:06 ` juergen.reuter at desy dot de
2015-07-06 10:26 ` vehre at gcc dot gnu.org
2015-07-09 10:42 ` vehre at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).