Reduce heap trashing due to std::string construction / concatenation via caching of section flags string representations

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54842 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Anton Korobeynikov
2008-08-16 12:57:07 +00:00
parent 7c856c09cd
commit d0c1e29aec
8 changed files with 35 additions and 9 deletions

View File

@@ -148,7 +148,7 @@ ELFTargetAsmInfo::MergeableStringSection(const GlobalVariable *GV) const {
return getReadOnlySection_();
}
std::string ELFTargetAsmInfo::PrintSectionFlags(unsigned flags) const {
std::string ELFTargetAsmInfo::printSectionFlags(unsigned flags) const {
std::string Flags = ",\"";
if (!(flags & SectionFlags::Debug))