From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 8C85A386100B; Tue, 15 Dec 2020 10:12:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8C85A386100B From: "pexu@gcc-bugzilla.mail.kapsi.fi" To: gcc-bugs@gcc.gnu.org Subject: [Bug lto/98275] -flto=auto fails if nthreads_var is zero, must not pass -j0 Date: Tue, 15 Dec 2020 10:12:47 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: lto X-Bugzilla-Version: 10.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: pexu@gcc-bugzilla.mail.kapsi.fi X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: FIXED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: marxin at gcc dot gnu.org X-Bugzilla-Target-Milestone: 11.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: 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, 15 Dec 2020 10:12:47 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D98275 --- Comment #4 from Pekka S --- (I wrote this prior the ticked was modifed and the patch committed.) Thanks. Applied the patch on the latest trunk, built aarch64-none-gcc cross compiler (mingw64). Using -flto=3Dauto -v reports `LTO parallelism level set to 1' = and `make -f -j1 all'; Linking now succeeds. Tested using GNU make 4.2.93 and 4.3 (msys2). I do not know whether or not the number of processors should be actually detectable. I presume I'll be simply using -flto=3DN (N>1) as it appears t= o work just fine. As a side note behaviour is now slightly different between -flto=3Dauto if nthreads_var<=3D1 and -flto=3DN where N<=3D1.=