diff --git a/lld/include/lld/ReaderWriter/ELFLinkingContext.h b/lld/include/lld/ReaderWriter/ELFLinkingContext.h index 93f84b59c7f7..c6a8ebf7fb62 100644 --- a/lld/include/lld/ReaderWriter/ELFLinkingContext.h +++ b/lld/include/lld/ReaderWriter/ELFLinkingContext.h @@ -307,7 +307,6 @@ protected: bool _noInhibitExec; bool _exportDynamic; bool _mergeCommonStrings; - bool _runLayoutPass; bool _useShlibUndefines; bool _dynamicLinkerArg; bool _noAllowDynamicLibraries; diff --git a/lld/lib/ReaderWriter/ELF/ELFLinkingContext.cpp b/lld/lib/ReaderWriter/ELF/ELFLinkingContext.cpp index 446ac9021211..93ccf7a1214c 100644 --- a/lld/lib/ReaderWriter/ELF/ELFLinkingContext.cpp +++ b/lld/lib/ReaderWriter/ELF/ELFLinkingContext.cpp @@ -59,15 +59,14 @@ ELFLinkingContext::ELFLinkingContext( : _outputELFType(llvm::ELF::ET_EXEC), _triple(triple), _targetHandler(std::move(targetHandler)), _baseAddress(0), _isStaticExecutable(false), _noInhibitExec(false), _exportDynamic(false), - _mergeCommonStrings(false), _runLayoutPass(true), - _useShlibUndefines(true), _dynamicLinkerArg(false), - _noAllowDynamicLibraries(false), _mergeRODataToTextSegment(true), - _demangle(true), _alignSegments(true), _outputMagic(OutputMagic::DEFAULT), - _initFunction("_init"), _finiFunction("_fini"), _sysrootPath("") {} + _mergeCommonStrings(false), _useShlibUndefines(true), + _dynamicLinkerArg(false), _noAllowDynamicLibraries(false), + _mergeRODataToTextSegment(true), _demangle(true), _alignSegments(true), + _outputMagic(OutputMagic::DEFAULT), _initFunction("_init"), + _finiFunction("_fini"), _sysrootPath("") {} void ELFLinkingContext::addPasses(PassManager &pm) { - if (_runLayoutPass) - pm.add(std::unique_ptr(new LayoutPass(registry()))); + pm.add(std::unique_ptr(new LayoutPass(registry()))); pm.add(std::unique_ptr(new elf::ArrayOrderPass())); }