From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 27A443858C52; Thu, 28 Sep 2023 09:48:07 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 27A443858C52 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1695894487; bh=jtT7bEx6LV3v2RHx7eMXEXHgTZ5MyIXEq9fZC+7f728=; h=From:To:Subject:Date:In-Reply-To:References:From; b=HSqPD989deHxoGYPZLG+J7Bwv9GpcWpwMb3rxpIw8SqD1y5Lc69ui7RimQapTMpR9 6Ttj4oFhAV4VVxHbBgWa/dgL57YianpYKBbloyKz6bmyV6YmM3iTHhtNJ5R689ImVX cf2sGqDYRt9mRyHIvqDm9//cC/8jw6MgKC5HfgCA= From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/111600] [14 Regression] RISC-V bootstrap time regression Date: Thu, 28 Sep 2023 09:47:59 +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: 14.0 X-Bugzilla-Keywords: compile-time-hog, needs-bisection X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org 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: 14.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: see_also 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D111600 Richard Biener changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://gcc.gnu.org/bugzill | |a/show_bug.cgi?id=3D111622 --- Comment #10 from Richard Biener --- Compiling insn-opinit.ii with a cross compiler at -O2 shows (checking enabl= ed but -fno-checking) scheduling : 34.48 ( 47%) 0.01 ( 1%) 34.50 ( = 46%) 7576k ( 1%) I don't run into the stack space issue with using the cross, but GCC tries to up the stack limit and appearantly qemu doesn't implement that. With a hard limit of 8MB (our default soft limit) I hit the recursion issue also with a cross. The backtrace is Program received signal SIGSEGV, Segmentation fault. 0x0000000001808aff in range_query::get_tree_range (this=3Dthis@entry=3D0x5f= 540f0, r=3D..., expr=3Dexpr@entry=3D, stmt=3D) at /space/rguenther/src/gcc/gcc/value-query.cc:163 163 i.set (TREE_TYPE (expr), w, w); (gdb) bt #0 0x0000000001808aff in range_query::get_tree_range (this=3Dthis@entry=3D0x5f540f0, r=3D...,=20 expr=3Dexpr@entry=3D, stmt=3D) at /space/rguenther/src/gcc/gcc/value-query.cc:163 #1 0x000000000273f7c6 in gimple_ranger::range_of_expr (this=3D0x5f540f0, r= =3D..., expr=3D,=20 stmt=3D) at /space/rguenther/src/gcc/gcc/gimple-range.cc= :86 #2 0x00000000016dd2ce in get_range (val=3Dval@entry=3D, stmt=3D,=20 minmax=3Dminmax@entry=3D0x7fffff7ff9b0, rvals=3D) at /space/rguenther/src/gcc/gcc/tree-ssa-strlen.cc:219 #3 0x0000000001358656 in get_offset_range (x=3D,=20 stmt=3Dstmt@entry=3D, r=3Dr@entry=3D0x7ff= fff7ffaf0, rvals=3D) at /space/rguenther/src/gcc/gcc/pointer-query.cc:93 #4 0x000000000135bd53 in handle_mem_ref (qry=3D0x41938e8, snlim=3D..., pref=3D0x7fffff7ffd90, ostype=3D,=20 stmt=3D, mref=3D) at /space/rguenther/src/gcc/gcc/pointer-query.cc:1995 #5 compute_objsize_r (ptr=3D, stmt=3D, addr=3Daddr@entry=3Dfalse,=20 ostype=3Dostype@entry=3D0, pref=3Dpref@entry=3D0x7fffff7ffd90, snlim=3D= ..., qry=3D0x41938e8) at /space/rguenther/src/gcc/gcc/pointer-query.cc:2262 #6 0x000000000136022a in compute_objsize (ptr=3D, stmt=3Dstmt@entry=3D,=20 ostype=3Dostype@entry=3D0, pref=3D0x7fffff7ffd90, ptr_qry=3D, ptr_qry@entry=3D0x41938e8) at /space/rguenther/src/gcc/gcc/pointer-query.cc:2368 #7 0x00000000013603f6 in pointer_query::get_ref (this=3Dthis@entry=3D0x419= 38e8, ptr=3Dptr@entry=3D,=20 stmt=3Dstmt@entry=3D, pref=3Dpref@entry=3D0x7fffff7ffd90, ostype=3Dostype@entry=3D0) at /space/rguenther/src/gcc/gcc/pointer-query.cc:1516 #8 0x00000000010d8a6d in (anonymous namespace)::pass_waccess::check_dangling_stores (this=3Dthis@entry=3D0x4193= 890,=20 bb=3D, stores=3D..., bbs=3D...) at /space/rguenther/src/gcc/gcc/gimple-ssa-warn-access.cc:4561 ... #18067 0x00000000010e1303 in (anonymous namespace)::pass_waccess::check_dangling_stores (this=3D0x4193890) at /space/rguenther/src/gcc/gcc/gimple-ssa-warn-access.cc:4640 4640 check_dangling_stores (EXIT_BLOCK_PTR_FOR_FN (m_func), stores, bb= s); I'll fix that. I also see insn-emit.cc compile (of the cross compiler) requiring 8GB of me= mory and multiple minutes (with a GCC 7 host compiler).=