Closed Bug 672694 Opened 9 years ago Closed 9 years ago
Add memory reporters to count compartments
I often count the number of compartments manually. It'd be nice (and easy) to automate this.
Should we telemeterize this?
Good idea, I'll do that.
This patch adds the js-compartment-count reporter. It doesn't telemeterize the counter, however. TelemetryPing.js has code that assumes that any UNITS_COUNT reporter reports a number that always increases, and so reports the change between pings. This makes sense for the page-fault counters, but not for js-compartment-count. I'll defer that to a follow-up bug (and assign it to jlebar, who implemented the current behaviour.) We might need to distinguish between UNITS_COUNT and UNITS_COUNT_INCREASING.
Attachment #546989 - Flags: review?(gal)
Summary: Add a memory reporter for the number of compartments → Add a js-compartment-count memory reporter
Summary: Add a js-compartment-count memory reporter → Add memory reporters to count compartments
I split this into two reporters: js-system-compartment-count and js-user-compartment-count, because knowing the split is useful, and summing them to get the overall count is trivial.
Whiteboard: [MemShrink] → [MemShrink][inbound]
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Whiteboard: [MemShrink][inbound] → [MemShrink]
Target Milestone: --- → mozilla8
The user vs system terminology (I realize it comes from the names in the code) is confusing. Do I understand correctly that the 'system' compartment basically counts compartments for the chrome code (as in "System principal")?
(In reply to comment #7) > > Do I understand correctly that the 'system' compartment basically counts > compartments for the chrome code (as in "System principal")? That's right. It also includes the 'atoms' compartment.
You need to log in before you can comment on or make changes to this bug.