https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89911
Bug ID: 89911 Summary: [9 Regression] ICE in get_attr_nonstring_decl, at calls.c:1502 Product: gcc Version: 9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: gs...@t-online.de Target Milestone: --- Changed between 20180610 and 20180624 : $ cat z1.c typedef __SIZE_TYPE__ size_t; extern size_t strnlen (); size_t foo () { return strnlen (); } $ gcc-9-20180610 -c z1.c $ $ gcc-9-20190331 -c z1.c z1.c: In function 'foo': z1.c:5:10: warning: too few arguments to built-in function 'strnlen' expecting 2 [-Wbuiltin-declaration-mismatch] 5 | return strnlen (); | ^~~~~~~ z1.c:2:15: note: declared here 2 | extern size_t strnlen (); | ^~~~~~~ during RTL pass: expand z1.c:5:10: internal compiler error: Segmentation fault 5 | return strnlen (); | ^~~~~~~~~~ 0xa748df crash_signal ../../gcc/toplev.c:326 0x6b02b1 get_attr_nonstring_decl(tree_node*, tree_node**) ../../gcc/calls.c:1502 0x6b23f9 maybe_warn_nonstring_arg(tree_node*, tree_node*) ../../gcc/calls.c:1615 0x6b7270 initialize_argument_information ../../gcc/calls.c:2209 0x6b7270 expand_call(tree_node*, rtx_def*, int) ../../gcc/calls.c:3589 0x6a6454 expand_builtin(tree_node*, rtx_def*, rtx_def*, machine_mode, int) ../../gcc/builtins.c:7233 0x7bd01e expand_expr_real_1(tree_node*, rtx_def*, machine_mode, expand_modifier, rtx_def**, bool) ../../gcc/expr.c:11029 0x7c71b6 store_expr(tree_node*, rtx_def*, int, bool, bool) ../../gcc/expr.c:5673 0x7c7f8e expand_assignment(tree_node*, tree_node*, bool) ../../gcc/expr.c:5436 0x6c6b50 expand_call_stmt ../../gcc/cfgexpand.c:2722 0x6c6b50 expand_gimple_stmt_1 ../../gcc/cfgexpand.c:3691 0x6c6b50 expand_gimple_stmt ../../gcc/cfgexpand.c:3850 0x6cba07 expand_gimple_basic_block ../../gcc/cfgexpand.c:5886 0x6ce096 execute ../../gcc/cfgexpand.c:6509