From owner-svn-src-head@freebsd.org Fri Sep 14 19:25:24 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 50B8C1091BB9; Fri, 14 Sep 2018 19:25:24 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 04F7E8EA86; Fri, 14 Sep 2018 19:25:24 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id F3848B1C; Fri, 14 Sep 2018 19:25:23 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w8EJPNFi046095; Fri, 14 Sep 2018 19:25:23 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w8EJPNGg046094; Fri, 14 Sep 2018 19:25:23 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201809141925.w8EJPNGg046094@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Fri, 14 Sep 2018 19:25:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r338689 - head/contrib/llvm/lib/CodeGen X-SVN-Group: head X-SVN-Commit-Author: dim X-SVN-Commit-Paths: head/contrib/llvm/lib/CodeGen X-SVN-Commit-Revision: 338689 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Sep 2018 19:25:24 -0000 Author: dim Date: Fri Sep 14 19:25:23 2018 New Revision: 338689 URL: https://svnweb.freebsd.org/changeset/base/338689 Log: Pull in r335365 from upstream llvm trunk (by Krzysztof Parzyszek): Initialize LiveRegs once in BranchFolder::mergeCommonTails This should fix '(TRI && "LivePhysRegs is not initialized."' assertions when building the lang/qt5-qml port in certain configurations. Approved by: re (kib) Reported by: Piotr Kubaj PR: 231355 MFC after: 3 days Modified: head/contrib/llvm/lib/CodeGen/BranchFolding.cpp Modified: head/contrib/llvm/lib/CodeGen/BranchFolding.cpp ============================================================================== --- head/contrib/llvm/lib/CodeGen/BranchFolding.cpp Fri Sep 14 18:12:30 2018 (r338688) +++ head/contrib/llvm/lib/CodeGen/BranchFolding.cpp Fri Sep 14 19:25:23 2018 (r338689) @@ -884,11 +884,12 @@ void BranchFolder::mergeCommonTails(unsigned commonTai if (UpdateLiveIns) { LivePhysRegs NewLiveIns(*TRI); computeLiveIns(NewLiveIns, *MBB); + LiveRegs.init(*TRI); // The flag merging may lead to some register uses no longer using the // flag, add IMPLICIT_DEFs in the predecessors as necessary. for (MachineBasicBlock *Pred : MBB->predecessors()) { - LiveRegs.init(*TRI); + LiveRegs.clear(); LiveRegs.addLiveOuts(*Pred); MachineBasicBlock::iterator InsertBefore = Pred->getFirstTerminator(); for (unsigned Reg : NewLiveIns) {