Esempio n. 1
0
void
BinMapOutput::InnerSectionsSymbols(const BinGroups& groups)
{
    for (BinGroups::const_iterator group = groups.begin(), end=groups.end();
         group != end; ++group)
    {
        if (CountSymbols(m_object, &group->m_section) > 0)
        {
            StringRef name = group->m_section.getName();
            m_os << "---- Section " << name << ' ';
            for (size_t i=0; i<65-name.size(); ++i)
                m_os << '-';

            m_os << "\n\n";
            m_os << format("%-*s", m_bytes*2+2, (const char*)"Real");
            m_os << format("%-*s", m_bytes*2+2, (const char*)"Virtual");
            m_os << "Name\n";
            OutputSymbols(&group->m_section);
            m_os << "\n\n";
        }

        // Recurse to loop through follow groups
        InnerSectionsSymbols(group->m_follow_groups);
    }
}
Esempio n. 2
0
void
BinMapOutput::OutputSectionsSymbols()
{
    m_os << "-- Symbols ";
    for (int i=0; i<68; ++i)
        m_os << '-';
    m_os << "\n\n";

    // We do two passes for EQU and each section; the first pass
    // determines the byte width to use for the value and whether any
    // symbols are present, the second pass actually outputs the text.

    // EQUs
    if (CountSymbols(m_object, 0) > 0)
    {
        m_os << "---- No Section ";
        for (int i=0; i<63; ++i)
            m_os << '-';
        m_os << "\n\n";
        m_os << format("%-*s", m_bytes*2+2, (const char*)"Value");
        m_os << "Name\n";
        OutputSymbols(0);
        m_os << "\n\n";
    }

    // Other sections
    InnerSectionsSymbols(m_groups);
}
Esempio n. 3
0
void
BinMapOutput::OutputSectionsSummary()
{
    m_os << "-- Sections (summary) ";
    for (int i=0; i<57; ++i)
        m_os << '-';

    m_os << "\n\n";
    m_os << format("%-*s", m_bytes*2+2, (const char*)"Vstart");
    m_os << format("%-*s", m_bytes*2+2, (const char*)"Vstop");
    m_os << format("%-*s", m_bytes*2+2, (const char*)"Start");
    m_os << format("%-*s", m_bytes*2+2, (const char*)"Stop");
    m_os << format("%-*s", m_bytes*2+2, (const char*)"Length");
    m_os << format("%-10s", (const char*)"Class");
    m_os << "Name\n";
    InnerSectionsSummary(m_groups);
    m_os << '\n';
}