From 5dfe0ffb0c2b0b1de3f1b37b1ad15566c5afac93 Mon Sep 17 00:00:00 2001 From: Davide Italiano Date: Fri, 6 Mar 2015 02:05:03 +0000 Subject: [PATCH] We want to add the entry point to the root set unconditionally, but these asserts don't allow us to do it. Remove them, they're not really needed anyway. llvm-svn: 231445 --- lld/include/lld/Core/LinkingContext.h | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/lld/include/lld/Core/LinkingContext.h b/lld/include/lld/Core/LinkingContext.h index 5a893ed..c3d1c4c 100644 --- a/lld/include/lld/Core/LinkingContext.h +++ b/lld/include/lld/Core/LinkingContext.h @@ -62,24 +62,19 @@ public: /// should be marked live (along with all Atoms they reference). Usually /// this method returns false for main executables, but true for dynamic /// shared libraries. - bool globalsAreDeadStripRoots() const { - assert(_deadStrip && "only applicable when deadstripping enabled"); - return _globalsAreDeadStripRoots; - } + bool globalsAreDeadStripRoots() const { return _globalsAreDeadStripRoots; }; /// Only used if deadStrip() returns true. This method returns the names /// of DefinedAtoms that should be marked live (along with all Atoms they /// reference). Only Atoms with scope scopeLinkageUnit or scopeGlobal can /// be kept live using this method. const std::vector &deadStripRoots() const { - assert(_deadStrip && "only applicable when deadstripping enabled"); return _deadStripRoots; } /// Add the given symbol name to the dead strip root set. Only used if /// deadStrip() returns true. void addDeadStripRoot(StringRef symbolName) { - assert(_deadStrip && "only applicable when deadstripping enabled"); assert(!symbolName.empty() && "Empty symbol cannot be a dead strip root"); _deadStripRoots.push_back(symbolName); } -- 2.7.4