From: Simon Atanasyan Date: Sat, 21 Jun 2014 08:36:12 +0000 (+0000) Subject: [Mips] Remove redundant checking from the RelocationPass::isDynamic() function. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=fa3016839528e459016aa624121429b240004a8f;p=platform%2Fupstream%2Fllvm.git [Mips] Remove redundant checking from the RelocationPass::isDynamic() function. No functional changes. llvm-svn: 211431 --- diff --git a/lld/lib/ReaderWriter/ELF/Mips/MipsRelocationPass.cpp b/lld/lib/ReaderWriter/ELF/Mips/MipsRelocationPass.cpp index 5e50725..237a733 100644 --- a/lld/lib/ReaderWriter/ELF/Mips/MipsRelocationPass.cpp +++ b/lld/lib/ReaderWriter/ELF/Mips/MipsRelocationPass.cpp @@ -479,14 +479,7 @@ bool RelocationPass::requireCopy(Reference &ref) { if (!_hasStaticRelocations.count(ref.target())) return false; const auto *sa = dyn_cast>(ref.target()); - if (sa && sa->type() != SharedLibraryAtom::Type::Data) - return false; - const auto *da = dyn_cast>(ref.target()); - if (da && da->contentType() != DefinedAtom::typeData) - return false; - if (isLocalCall(ref.target())) - return false; - return true; + return sa && sa->type() == SharedLibraryAtom::Type::Data; } template