Lines Matching defs:sections

78 // We allow sections of types listed below to merged into a
81 // to be allocated for nobits sections. Other ones don't require
85 // NOTE: clang since rL252300 emits SHT_X86_64_UNWIND .eh_frame sections. Allow
100 // 2. Add the InputSection to the InputSectionDescription::sections.
192 // InputSectionDescription::sections.
195 // new synthetic sections at the location of the first input section
205 isd->sections.reserve(isd->sectionBases.size());
209 isd->sections.push_back(cast<InputSection>(s));
213 // We do not want to handle sections that are not alive, so just remove
223 // could be equal, so we may as well have two sections.
238 isd->sections.push_back(syn);
252 // Some input sections may be removed from the list after ICF.
253 for (InputSection *s : isd->sections)
258 // the alignment of potential spill sections and their containing output
259 // sections.
293 sortByOrder(isd->sections, order);
333 Err(ctx) << "--compress-sections: deflateInit2 returned " << res;
360 // Compress certain non-SHF_ALLOC sections:
362 // * (if --compress-debug-sections is specified) non-empty .debug_* sections
363 // * (if --compress-sections is specified) matched sections
380 Err(ctx) << "--compress-sections: section '" << name
385 llvm::TimeTraceScope timeScope("Compress sections");
396 // useful when there are many compressed output sections.
492 llvm::TimeTraceScope timeScope("Write sections", name);
502 // --compress-debug-section/--compress-sections, the content is already known.
529 ArrayRef<InputSection *> sections = getInputSections(*this, storage);
533 fill(buf, sections.empty() ? size : sections[0]->outSecOff, filler);
542 size_t numSections = sections.size();
544 InputSection *isec = sections[i];
556 // Fill gaps between sections.
563 end = buf + sections[i + 1]->outSecOff;
577 size_t numSections = sections.size();
589 // time with other output sections. Note, if a linker script specifies
590 // overlapping output sections (needs --noinhibit-exec or --no-check-sections
594 taskSize += sections[i]->getSize();
608 // sh_link field for SHT_GROUP sections should contain the section index of
623 ArrayRef<InputSectionBase *> sections = section->file->getSections();
625 if (OutputSection *osec = sections[read32(ctx, &idx)]->getOutputSection())
694 // Input CREL sections are decoded while REL[A] need to be converted.
702 for (InputSection *relSec : isd->sections) {
735 // We must preserve the link order dependency of sections with the
762 // sh_info for SHT_REL[A] sections should contain the section header index of
799 // For 2 and 3, the sections are sorted by priority from high to low, e.g.
821 // Sorts input sections by the special rules for .ctors and .dtors.
827 llvm::stable_sort(isd->sections, compCtors);
847 if (!isd->sections.empty())
848 return isd->sections[0];
862 ret = isd->sections;
866 storage.insert(storage.end(), isd->sections.begin(), isd->sections.end());
872 // Sorts input sections by section name suffixes, so that .foo.N comes
873 // before .foo.M if N < M. Used to sort .{init,fini}_array.N sections.
879 // Sort sections by priority.
895 ArrayRef<InputSection *> sections = getInputSections(*this, storage);
896 parallelFor(0, sections.size(), [&](size_t i) {
898 // for input .rel[a].<sec> sections which we simply pass through to the
900 // sections created during linking.
901 if (!SyntheticSection::classof(sections[i]) ||
903 sections[i]->type))
905 const auto *sec = cast<RelocationBaseSection>(sections[i]);
912 // Some targets have NOBITS synthetic sections with dynamic relocations
913 // with non-zero addends. Skip such sections.