Closed Bug 512003 Opened 15 years ago Closed 15 years ago

GC::gclog calls heap->DumpMemoryInfo() unpredictably

Categories

(Tamarin Graveyard :: Garbage Collection (mmGC), defect)

defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: stejohns, Assigned: stejohns)

Details

Attachments

(1 file, 1 obsolete file)

GC::gclog calls heap->DumpMemoryInfo() in order to log gross stats any time anything interesting happens. It uses a global to prevent recursion, but neglects to clear it properly every time, resulting in output that is sensitive to timing, since some triggers are time-based (eg Sweep) and some triggers are processing-time based (eg ZCTReap). This manifests in memory profiling that is erratic. Enclosed is a patch that does what I presume this code intends to do (namely, call DumpMemoryInfo() every top-level call to gclog).
Attached patch Patch (obsolete) — Splinter Review
Assignee: nobody → stejohns
Attachment #395974 - Flags: superreview?(edwsmith)
Attachment #395974 - Flags: review?(treilly)
Hmm, didn't know about https://bugzilla.mozilla.org/show_bug.cgi?id=495443 when I wrote this. Still, the observed bugginess applies...
Flags: flashplayer-qrb?
Attachment #395974 - Flags: superreview?(edwsmith) → superreview?(lhansen)
Attached patch Patch #2Splinter Review
Same as previous patch, but don't do memory dumps during gc teardown (destroying==true); it appears that some as-yet-unexplained oddities of mprotect() [on Leopard, anyway] can cause private pages to be brought back resident, skewing our measured memory numbers upwards. It's worth figuring out what's going on, but as a temporary band-aid, skipping memstats during gc teardown seems like a plausible fix...
Attachment #395974 - Attachment is obsolete: true
Attachment #396241 - Flags: superreview?(lhansen)
Attachment #396241 - Flags: review?(treilly)
Attachment #395974 - Flags: superreview?(lhansen)
Attachment #395974 - Flags: review?(treilly)
Attachment #396241 - Flags: superreview?(lhansen) → superreview+
Status: NEW → ASSIGNED
Flags: flashplayer-qrb? → flashplayer-qrb+
Attachment #396241 - Flags: review?(treilly) → review+
pushed to redux as changeset:   2408:f0042ab548d9
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Resolved fixed engineering / work item that has been pushed.  Setting status to verified.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: