Closed Bug 1302125 Opened 8 years ago Closed 8 years ago

Cap the number of lines in "GC found live" logging by default

Categories

(Core :: JavaScript: GC, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla51
Tracking Status
firefox51 --- fixed

People

(Reporter: mccr8, Assigned: sfink)

References

Details

Attachments

(1 file)

This logging is way too spammy. For instance, about a third of this log is "GC found live" output: https://treeherder.mozilla.org/logviewer.html#?job_id=4824714&repo=mozilla-central The total output should be capped at, say, 20 lines. Maybe it could also print out the total number of found live objects, and have an environment variable to print them all out, but the current default is not okay. It also makes investigating leaks locally difficult.
Does this look about right? I didn't test with an actual leaking browser, though I did compile once skipping is ``if (!arenaLists[kind].isEmpty())`` test, and it at least printed out the total of 0.
Attachment #8790484 - Flags: review?(continuation)
Assignee: nobody → sphink
Status: NEW → ASSIGNED
Comment on attachment 8790484 [details] [diff] [review] Limit number of ERROR: GC found live Cell messages Review of attachment 8790484 [details] [diff] [review]: ----------------------------------------------------------------- Thanks. ::: js/src/jsgc.cpp @@ +3572,3 @@ > #ifdef DEBUG > if (!arenaLists[kind].isEmpty()) { > + size_t max_cells = 20; Make this const?
Attachment #8790484 - Flags: review?(continuation) → review+
(In reply to Andrew McCreight [:mccr8] from comment #2) > @@ +3572,3 @@ > > #ifdef DEBUG > > if (!arenaLists[kind].isEmpty()) { > > + size_t max_cells = 20; > > Make this const? Can't. I'm setting it to $JS_GC_MAX_LIVE_CELLS if given. I really ought to make a more generic mechanism for configuring all this tracing and profiling goop, I suppose.
Pushed by sfink@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/c68f029d6c55 Limit number of ERROR: GC found live Cell messages, r=mccr8
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla51
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: