From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 94A513858C27; Mon, 7 Feb 2022 18:49:37 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 94A513858C27 From: "gscfq@t-online.de" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/104430] New: [9/10/11/12 Regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.cc:2742 Date: Mon, 07 Feb 2022 18:49:37 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: gscfq@t-online.de X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: 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 bug_severity priority component assigned_to reporter target_milestone Message-ID: 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-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Feb 2022 18:49:37 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D104430 Bug ID: 104430 Summary: [9/10/11/12 Regression] ICE in gfc_conv_component_ref, at fortran/trans-expr.cc:2742 Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: gscfq@t-online.de Target Milestone: --- Starts with r8, basically r9 changed between 20181014 and 20181021 : $ cat z1.f90 module m type t integer :: a end type contains function f(x) result(z) class(t) :: x(:) type(t) :: z(size(x%a)) end end program p use m class(t), allocatable :: y(:), z(:) z =3D f(y) end $ gfortran-7 -c z1.f90 $ $ gfortran-12-20220206 -c z1.f90 z1.f90:14:11: 14 | z =3D f(y) | 1 internal compiler error: Segmentation fault 0xe6fc6f crash_signal ../../gcc/toplev.cc:322 0x8265df tree_check3(tree_node*, char const*, int, char const*, tree_code, tree_code, tree_code) ../../gcc/tree.h:3483 0x8265df gfc_conv_component_ref(gfc_se*, gfc_ref*) ../../gcc/fortran/trans-expr.cc:2742 0x837897 gfc_conv_variable ../../gcc/fortran/trans-expr.cc:3118 0x83264a gfc_conv_expr(gfc_se*, gfc_expr*) ../../gcc/fortran/trans-expr.cc:9406 0x835760 gfc_conv_expr_lhs(gfc_se*, gfc_expr*) ../../gcc/fortran/trans-expr.cc:9436 0x7f0858 gfc_conv_ss_descriptor ../../gcc/fortran/trans-array.cc:3219 0x7fd2e5 gfc_conv_expr_descriptor(gfc_se*, gfc_expr*) ../../gcc/fortran/trans-array.cc:7494 0x8462cf gfc_conv_intrinsic_size ../../gcc/fortran/trans-intrinsic.cc:7975 0x86295b gfc_conv_intrinsic_function(gfc_se*, gfc_expr*) ../../gcc/fortran/trans-intrinsic.cc:10644 0x83262a gfc_conv_expr(gfc_se*, gfc_expr*) ../../gcc/fortran/trans-expr.cc:9398 0x834b5a gfc_apply_interface_mapping(gfc_interface_mapping*, gfc_se*, gfc_expr*) ../../gcc/fortran/trans-expr.cc:4865 0x7ee747 gfc_set_loop_bounds_from_array_spec(gfc_interface_mapping*, gfc_se= *, gfc_array_spec*) ../../gcc/fortran/trans-array.cc:1080 0x83066f gfc_conv_procedure_call(gfc_se*, gfc_symbol*, gfc_actual_arglist*, gfc_expr*, vec*) ../../gcc/fortran/trans-expr.cc:7472 0x8426ac gfc_trans_arrayfunc_assign ../../gcc/fortran/trans-expr.cc:10873 0x8428d4 gfc_trans_assignment(gfc_expr*, gfc_expr*, bool, bool, bool, bool) ../../gcc/fortran/trans-expr.cc:12038 0x7e9887 trans_code ../../gcc/fortran/trans.cc:1916 0x8207a9 gfc_generate_function_code(gfc_namespace*) ../../gcc/fortran/trans-decl.cc:7654 0x7931fe translate_all_program_units ../../gcc/fortran/parse.cc:6651 0x7931fe gfc_parse_file() ../../gcc/fortran/parse.cc:6938=