From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 69CFA3857726; Thu, 8 Jun 2023 03:18:31 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 69CFA3857726 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1686194311; bh=ZP/syG6zf8DKxjIkoi7+W3vZsOdwwoXU2RqwGT7XpEU=; h=From:To:Subject:Date:From; b=xPAtd3QeQ/8MLHoIwUTZKa6in7ZZVSJ4lAjtcrUHyFLrY1Vxhbr3zPgG0AvAJgrM+ /hsZwavhTZGGjTVrULxZJbPycS41UjkHfv4C20txZQbbtMMGemeszW4Si19RooePGT zX5IcDxwuPfjwjRlUkmmRZgKhwvqGX7QDNm2ZLhI= From: "nightstrike at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/110167] New: excessive compile time when optimizing std::to_array Date: Thu, 08 Jun 2023 03:18:30 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libstdc++ X-Bugzilla-Version: 13.1.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: nightstrike at gmail dot com 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D110167 Bug ID: 110167 Summary: excessive compile time when optimizing std::to_array Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: nightstrike at gmail dot com Target Milestone: --- #include int f[262144]; auto g(void) { return std::to_array(f); } (Thanks to Andrew for help reducing!) Baseline run: $ time g++ test.cc -std=3Dgnu++20 -O0 -c real 0m17.274s user 0m16.806s sys 0m0.119s at -O1, 2, 3, or fast, it takes too long to ever finish. I killed it after= 15 minutes. For the curious, that array size is 512*512. I didn't bisect to see where = it starts to blow up.=