diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2017-12-06 18:56:22 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2017-12-06 18:56:22 +0000 |
commit | c8dfde2051d66a2fd1426ec56d8c611e21afeef4 (patch) | |
tree | 50d55665dd5dae184d99b591600d0c8b6ef8d90c | |
parent | 9c60c7dcf4aa0dd1fe263f3668faf5a39d2548b0 (diff) | |
download | bcm5719-llvm-c8dfde2051d66a2fd1426ec56d8c611e21afeef4.tar.gz bcm5719-llvm-c8dfde2051d66a2fd1426ec56d8c611e21afeef4.zip |
Replace one use of check with checkLazy.
Reduce total allocation when linking clang from 320.04MB to 300.82MB.
llvm-svn: 319924
-rw-r--r-- | lld/ELF/InputFiles.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lld/ELF/InputFiles.cpp b/lld/ELF/InputFiles.cpp index 7bd8a814959..52b30f722f4 100644 --- a/lld/ELF/InputFiles.cpp +++ b/lld/ELF/InputFiles.cpp @@ -595,8 +595,8 @@ InputSectionBase *ObjFile<ELFT>::createInputSection(const Elf_Shdr &Sec) { template <class ELFT> StringRef ObjFile<ELFT>::getSectionName(const Elf_Shdr &Sec) { - return check(this->getObj().getSectionName(&Sec, SectionStringTable), - toString(this)); + return checkLazy(this->getObj().getSectionName(&Sec, SectionStringTable), + [=]() { return toString(this); }); } template <class ELFT> void ObjFile<ELFT>::initializeSymbols() { |