From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 506F2382E06B; Tue, 9 Mar 2021 19:59:21 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 506F2382E06B From: "msebor at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/99489] [11 Regression] internal compiler error: during GIMPLE pass: strlen in dlt_logstorage_log_file_name() Date: Tue, 09 Mar 2021 19:59:21 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: tree-optimization X-Bugzilla-Version: 11.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: msebor at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: msebor at gcc dot gnu.org X-Bugzilla-Target-Milestone: 11.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: see_also bug_status assigned_to Message-ID: In-Reply-To: References: 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: Tue, 09 Mar 2021 19:59:21 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D99489 Martin Sebor changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://gcc.gnu.org/bugzill | |a/show_bug.cgi?id=3D82429 Status|NEW |ASSIGNED Assignee|unassigned at gcc dot gnu.org |msebor at gcc dot g= nu.org --- Comment #5 from Martin Sebor --- Reduced test case (the stpcpy declaration is important because of the hack described in pr82429): $ cat v.c && gcc -O2 -S -Wall v.c char *stpcpy (char *, const char *); void f (char *d, char c, char *s) { __builtin_strcat (d, s); __builtin_strncat (d, &c, 1); } during GIMPLE pass: strlen v.c: In function =E2=80=98f=E2=80=99: v.c:3:6: internal compiler error: gimple check: expected gimple_call(error_mark), have gimple_nop() in gimple_call_fndecl, at gimple.h:3171 3 | void f (char *d, char c, char *s) | ^ 0xe66115 gimple_check_failed(gimple const*, char const*, int, char const*, gimple_code, tree_code) /src/gcc/master/gcc/gimple.c:1259 0xbb23bf GIMPLE_CHECK2 /src/gcc/master/gcc/gimple.h:74 0xb7bbe1 gimple_call_fndecl /src/gcc/master/gcc/gimple.h:3171 0xb8edf0 gimple_call_alloc_size(gimple*, generic_wide_int= *, range_query*) /src/gcc/master/gcc/builtins.c:4931 0x15cc71e handle_builtin_stxncpy_strncat /src/gcc/master/gcc/tree-ssa-strlen.c:3109 0x15caea9 handle_builtin_strncat /src/gcc/master/gcc/tree-ssa-strlen.c:2666 0x15d214f strlen_check_and_optimize_call /src/gcc/master/gcc/tree-ssa-strlen.c:5166 0x15d2d30 check_and_optimize_stmt /src/gcc/master/gcc/tree-ssa-strlen.c:5374 0x15d3917 strlen_dom_walker::before_dom_children(basic_block_def*) /src/gcc/master/gcc/tree-ssa-strlen.c:5626 0x22901c2 dom_walker::walk(basic_block_def*) /src/gcc/master/gcc/domwalk.c:309 0x15d3c0e printf_strlen_execute /src/gcc/master/gcc/tree-ssa-strlen.c:5692 0x15d3fa4 execute /src/gcc/master/gcc/tree-ssa-strlen.c:5814 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See for instructions.=