Date: Fri, 15 Dec 2017 18:56:13 +0000 (UTC) From: Ed Maste <emaste@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r326879 - head/contrib/llvm/tools/lld/ELF Message-ID: <201712151856.vBFIuDNY032327@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: emaste Date: Fri Dec 15 18:56:12 2017 New Revision: 326879 URL: https://svnweb.freebsd.org/changeset/base/326879 Log: lld: Simplify a boolean expression by De Morgan's laws. Cherry-pick lld r315653 by Rui Ueyama: I don't really understand what exactly this expression means, but at least I can mechanically transform it. Obtained from: LLVM r315653 MFC after: 1 week Modified: head/contrib/llvm/tools/lld/ELF/Relocations.cpp Modified: head/contrib/llvm/tools/lld/ELF/Relocations.cpp ============================================================================== --- head/contrib/llvm/tools/lld/ELF/Relocations.cpp Fri Dec 15 18:09:23 2017 (r326878) +++ head/contrib/llvm/tools/lld/ELF/Relocations.cpp Fri Dec 15 18:56:12 2017 (r326879) @@ -790,7 +790,7 @@ static void addGotEntry(SymbolBody &Sym, bool Preempti DynType = Target->GotRel; } - bool Constant = !Preemptible && !(Config->Pic && !isAbsolute(Sym)); + bool Constant = !Preemptible && (!Config->Pic || isAbsolute(Sym)); if (!Constant) In<ELFT>::RelaDyn->addReloc( {DynType, InX::Got, Off, !Preemptible, &Sym, 0});
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201712151856.vBFIuDNY032327>