Lines Matching defs:Section

1357   IO.mapOptional("Section", Symbol.Section);
1375 if (Symbol.Index && Symbol.Section)
1376 return "Index and Section cannot both be specified for Symbol";
1380 static void commonSectionMapping(IO &IO, ELFYAML::Section &Section) {
1381 IO.mapOptional("Name", Section.Name, StringRef());
1382 IO.mapRequired("Type", Section.Type);
1383 IO.mapOptional("Flags", Section.Flags);
1384 IO.mapOptional("Address", Section.Address);
1385 IO.mapOptional("Link", Section.Link);
1386 IO.mapOptional("AddressAlign", Section.AddressAlign, Hex64(0));
1387 IO.mapOptional("EntSize", Section.EntSize);
1388 IO.mapOptional("Offset", Section.Offset);
1390 IO.mapOptional("Content", Section.Content);
1391 IO.mapOptional("Size", Section.Size);
1397 (!Section.ShOffset && !Section.ShSize && !Section.ShName &&
1398 !Section.ShFlags && !Section.ShType && !Section.ShAddrAlign));
1399 IO.mapOptional("ShAddrAlign", Section.ShAddrAlign);
1400 IO.mapOptional("ShName", Section.ShName);
1401 IO.mapOptional("ShOffset", Section.ShOffset);
1402 IO.mapOptional("ShSize", Section.ShSize);
1403 IO.mapOptional("ShFlags", Section.ShFlags);
1404 IO.mapOptional("ShType", Section.ShType);
1407 static void sectionMapping(IO &IO, ELFYAML::DynamicSection &Section) {
1408 commonSectionMapping(IO, Section);
1409 IO.mapOptional("Entries", Section.Entries);
1412 static void sectionMapping(IO &IO, ELFYAML::RawContentSection &Section) {
1413 commonSectionMapping(IO, Section);
1417 assert(!IO.outputting() || !Section.ContentBuf);
1418 IO.mapOptional("ContentArray", Section.ContentBuf);
1419 if (Section.ContentBuf) {
1420 if (Section.Content)
1422 Section.Content = yaml::BinaryRef(*Section.ContentBuf);
1425 IO.mapOptional("Info", Section.Info);
1428 static void sectionMapping(IO &IO, ELFYAML::BBAddrMapSection &Section) {
1429 commonSectionMapping(IO, Section);
1430 IO.mapOptional("Content", Section.Content);
1431 IO.mapOptional("Entries", Section.Entries);
1432 IO.mapOptional("PGOAnalyses", Section.PGOAnalyses);
1435 static void sectionMapping(IO &IO, ELFYAML::StackSizesSection &Section) {
1436 commonSectionMapping(IO, Section);
1437 IO.mapOptional("Entries", Section.Entries);
1440 static void sectionMapping(IO &IO, ELFYAML::HashSection &Section) {
1441 commonSectionMapping(IO, Section);
1442 IO.mapOptional("Bucket", Section.Bucket);
1443 IO.mapOptional("Chain", Section.Chain);
1447 assert(!IO.outputting() || (!Section.NBucket && !Section.NChain));
1448 IO.mapOptional("NChain", Section.NChain);
1449 IO.mapOptional("NBucket", Section.NBucket);
1452 static void sectionMapping(IO &IO, ELFYAML::NoteSection &Section) {
1453 commonSectionMapping(IO, Section);
1454 IO.mapOptional("Notes", Section.Notes);
1458 static void sectionMapping(IO &IO, ELFYAML::GnuHashSection &Section) {
1459 commonSectionMapping(IO, Section);
1460 IO.mapOptional("Header", Section.Header);
1461 IO.mapOptional("BloomFilter", Section.BloomFilter);
1462 IO.mapOptional("HashBuckets", Section.HashBuckets);
1463 IO.mapOptional("HashValues", Section.HashValues);
1465 static void sectionMapping(IO &IO, ELFYAML::NoBitsSection &Section) {
1466 commonSectionMapping(IO, Section);
1469 static void sectionMapping(IO &IO, ELFYAML::VerdefSection &Section) {
1470 commonSectionMapping(IO, Section);
1471 IO.mapOptional("Info", Section.Info);
1472 IO.mapOptional("Entries", Section.Entries);
1475 static void sectionMapping(IO &IO, ELFYAML::SymverSection &Section) {
1476 commonSectionMapping(IO, Section);
1477 IO.mapOptional("Entries", Section.Entries);
1480 static void sectionMapping(IO &IO, ELFYAML::VerneedSection &Section) {
1481 commonSectionMapping(IO, Section);
1482 IO.mapOptional("Info", Section.Info);
1483 IO.mapOptional("Dependencies", Section.VerneedV);
1486 static void sectionMapping(IO &IO, ELFYAML::RelocationSection &Section) {
1487 commonSectionMapping(IO, Section);
1488 IO.mapOptional("Info", Section.RelocatableSec, StringRef());
1489 IO.mapOptional("Relocations", Section.Relocations);
1492 static void sectionMapping(IO &IO, ELFYAML::RelrSection &Section) {
1493 commonSectionMapping(IO, Section);
1494 IO.mapOptional("Entries", Section.Entries);
1503 static void sectionMapping(IO &IO, ELFYAML::SymtabShndxSection &Section) {
1504 commonSectionMapping(IO, Section);
1505 IO.mapOptional("Entries", Section.Entries);
1508 static void sectionMapping(IO &IO, ELFYAML::AddrsigSection &Section) {
1509 commonSectionMapping(IO, Section);
1510 IO.mapOptional("Symbols", Section.Symbols);
1528 static void sectionMapping(IO &IO, ELFYAML::LinkerOptionsSection &Section) {
1529 commonSectionMapping(IO, Section);
1530 IO.mapOptional("Options", Section.Options);
1534 ELFYAML::DependentLibrariesSection &Section) {
1535 commonSectionMapping(IO, Section);
1536 IO.mapOptional("Libraries", Section.Libs);
1539 static void sectionMapping(IO &IO, ELFYAML::CallGraphProfileSection &Section) {
1540 commonSectionMapping(IO, Section);
1541 IO.mapOptional("Entries", Section.Entries);
1549 static void sectionMapping(IO &IO, ELFYAML::ARMIndexTableSection &Section) {
1550 commonSectionMapping(IO, Section);
1551 IO.mapOptional("Entries", Section.Entries);
1554 static void sectionMapping(IO &IO, ELFYAML::MipsABIFlags &Section) {
1555 commonSectionMapping(IO, Section);
1556 IO.mapOptional("Version", Section.Version, Hex16(0));
1557 IO.mapRequired("ISA", Section.ISALevel);
1558 IO.mapOptional("ISARevision", Section.ISARevision, Hex8(0));
1559 IO.mapOptional("ISAExtension", Section.ISAExtension,
1561 IO.mapOptional("ASEs", Section.ASEs, ELFYAML::MIPS_AFL_ASE(0));
1562 IO.mapOptional("FpABI", Section.FpABI,
1564 IO.mapOptional("GPRSize", Section.GPRSize,
1566 IO.mapOptional("CPR1Size", Section.CPR1Size,
1568 IO.mapOptional("CPR2Size", Section.CPR2Size,
1570 IO.mapOptional("Flags1", Section.Flags1, ELFYAML::MIPS_AFL_FLAGS1(0));
1571 IO.mapOptional("Flags2", Section.Flags2, Hex32(0));
1590 IO &IO, std::unique_ptr<ELFYAML::Chunk> &Section) {
1594 if (auto *S = dyn_cast<ELFYAML::Section>(Section.get()))
1596 else if (auto *SHT = dyn_cast<ELFYAML::SectionHeaderTable>(Section.get()))
1608 Section.reset(new ELFYAML::Fill());
1609 fillMapping(IO, *cast<ELFYAML::Fill>(Section.get()));
1617 Section.reset(new ELFYAML::SectionHeaderTable(/*IsImplicit=*/false));
1620 IO, *cast<ELFYAML::SectionHeaderTable>(Section.get()));
1627 Section.reset(new ELFYAML::MipsABIFlags());
1628 sectionMapping(IO, *cast<ELFYAML::MipsABIFlags>(Section.get()));
1634 Section.reset(new ELFYAML::ARMIndexTableSection());
1635 sectionMapping(IO, *cast<ELFYAML::ARMIndexTableSection>(Section.get()));
1642 Section.reset(new ELFYAML::DynamicSection());
1643 sectionMapping(IO, *cast<ELFYAML::DynamicSection>(Section.get()));
1649 Section.reset(new ELFYAML::RelocationSection());
1650 sectionMapping(IO, *cast<ELFYAML::RelocationSection>(Section.get()));
1654 Section.reset(new ELFYAML::RelrSection());
1655 sectionMapping(IO, *cast<ELFYAML::RelrSection>(Section.get()));
1659 Section.reset(new ELFYAML::GroupSection());
1660 groupSectionMapping(IO, *cast<ELFYAML::GroupSection>(Section.get()));
1664 Section.reset(new ELFYAML::NoBitsSection());
1665 sectionMapping(IO, *cast<ELFYAML::NoBitsSection>(Section.get()));
1669 Section.reset(new ELFYAML::HashSection());
1670 sectionMapping(IO, *cast<ELFYAML::HashSection>(Section.get()));
1674 Section.reset(new ELFYAML::NoteSection());
1675 sectionMapping(IO, *cast<ELFYAML::NoteSection>(Section.get()));
1679 Section.reset(new ELFYAML::GnuHashSection());
1680 sectionMapping(IO, *cast<ELFYAML::GnuHashSection>(Section.get()));
1684 Section.reset(new ELFYAML::VerdefSection());
1685 sectionMapping(IO, *cast<ELFYAML::VerdefSection>(Section.get()));
1689 Section.reset(new ELFYAML::SymverSection());
1690 sectionMapping(IO, *cast<ELFYAML::SymverSection>(Section.get()));
1694 Section.reset(new ELFYAML::VerneedSection());
1695 sectionMapping(IO, *cast<ELFYAML::VerneedSection>(Section.get()));
1699 Section.reset(new ELFYAML::SymtabShndxSection());
1700 sectionMapping(IO, *cast<ELFYAML::SymtabShndxSection>(Section.get()));
1704 Section.reset(new ELFYAML::AddrsigSection());
1705 sectionMapping(IO, *cast<ELFYAML::AddrsigSection>(Section.get()));
1709 Section.reset(new ELFYAML::LinkerOptionsSection());
1710 sectionMapping(IO, *cast<ELFYAML::LinkerOptionsSection>(Section.get()));
1714 Section.reset(new ELFYAML::DependentLibrariesSection());
1716 *cast<ELFYAML::DependentLibrariesSection>(Section.get()));
1720 Section.reset(new ELFYAML::CallGraphProfileSection());
1721 sectionMapping(IO, *cast<ELFYAML::CallGraphProfileSection>(Section.get()));
1725 Section.reset(new ELFYAML::BBAddrMapSection());
1726 sectionMapping(IO, *cast<ELFYAML::BBAddrMapSection>(Section.get()));
1735 Section = std::make_unique<ELFYAML::StackSizesSection>();
1737 Section = std::make_unique<ELFYAML::RawContentSection>();
1740 if (auto S = dyn_cast<ELFYAML::RawContentSection>(Section.get()))
1743 sectionMapping(IO, *cast<ELFYAML::StackSizesSection>(Section.get()));
1763 const ELFYAML::Section &Sec = *cast<ELFYAML::Section>(C.get());
1766 return "Section size must be greater than or equal to the content size";