[Webkit-unassigned] [Bug 91227] New: Web Inspector: native memory instrumentation: extract instrumentation methods into MemoryClassInfo

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Jul 13 06:06:01 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=91227

           Summary: Web Inspector: native memory instrumentation: extract
                    instrumentation methods into MemoryClassInfo
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: All
        OS/Version: All
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: Web Inspector
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: loislo at chromium.org
                CC: timothy at apple.com, rik at webkit.org, keishi at webkit.org,
                    pmuellr at yahoo.com, joepeck at webkit.org,
                    pfeldman at chromium.org, yurys at chromium.org,
                    bweinstein at apple.com, apavlov at chromium.org,
                    loislo at chromium.org, alexeif at chromium.org


The API is not strong enough.
I'd like to modify it. The ideal target at the moment is instrumentation code like this:


void Node::visit(MemoryObjectInfo* memoryObjectInfo) const
{
    MemoryClassInfo<Node> info(memoryObjectInfo, this, MemoryInstrumentation::DOM);

    info.visitBaseClass<ScriptWrappable>(this);
    info.visitBaseClass<AnotherBaseClass>(this);

    info.addMember(m_notInstrumentedPointer); // automatically detects poniter/reference
    info.addMember(m_notInstrumentedObject);  // automatically detects poniter/reference

    info.addInstrumentedMember(m_next);
    info.addInstrumentedMember(m_previous);

    info.addHashSet<MemoryInstrumentation::NonClass>(m_aHash);                // NonClass value_type (report only size of internal template structures)
    info.addHashSet<MemoryInstrumentation::NotInstrumentedClass>(m_aHashSet); // not instrumented value_type (use sizeof)
    info.addHashSet<MemoryInstrumentation::InstrumentedClass>(m_aHashSet);    // instrumented value_type (call visit)

    // the same as for HashSet but for both template arguments
    info.addHashMap<MemoryInstrumentation::NonClass, MemoryInstrumentation::InstrumentedClass>(m_aHashSet);
    info.addHashMap<MemoryInstrumentation::ForwardDeclaredClass, MemoryInstrumentation::InstrumentedClass>(m_aHashSet);
}

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list