https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104312
Bug ID: 104312 Summary: ICE with -ff2c in fold_convert_loc, at fold-const.cc:2451 Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: gs...@t-online.de Target Milestone: --- Affects versions down to at least r5 : $ cat z1.f90 function f() real, pointer :: f, e entry e() end $ gfortran-12-20220130 -c z1.f90 $ $ gfortran-12-20220130 -c z1.f90 -ff2c z1.f90:1:0: 1 | function f() | internal compiler error: in fold_convert_loc, at fold-const.cc:2451 0x9b68e7 fold_convert_loc(unsigned int, tree_node*, tree_node*) ../../gcc/fold-const.cc:2450 0xa3130d gimplify_modify_expr ../../gcc/gimplify.cc:5918 0xa2901a gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*), int) ../../gcc/gimplify.cc:14963 0xa2bb48 gimplify_stmt(tree_node**, gimple**) ../../gcc/gimplify.cc:7035 0xa29306 gimplify_and_add(tree_node*, gimple**) ../../gcc/gimplify.cc:495 0xa29306 gimplify_return_expr ../../gcc/gimplify.cc:1677 0xa29306 gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*), int) ../../gcc/gimplify.cc:15225 0xa2bb48 gimplify_stmt(tree_node**, gimple**) ../../gcc/gimplify.cc:7035 0xa2c0a1 gimplify_bind_expr ../../gcc/gimplify.cc:1427 0xa2948a gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*), int) ../../gcc/gimplify.cc:15164 0xa2bb48 gimplify_stmt(tree_node**, gimple**) ../../gcc/gimplify.cc:7035 0xa2cbcb gimplify_body(tree_node*, bool) ../../gcc/gimplify.cc:16209 0xa2d01f gimplify_function_tree(tree_node*) ../../gcc/gimplify.cc:16363 0x8b3147 cgraph_node::analyze() ../../gcc/cgraphunit.cc:675 0x8b5af7 analyze_functions ../../gcc/cgraphunit.cc:1240 0x8b64bd symbol_table::finalize_compilation_unit() ../../gcc/cgraphunit.cc:2500