Jetpack's traits.js is 15mb memory for each instance

RESOLVED DUPLICATE of bug 724632

Status

P1
normal
RESOLVED DUPLICATE of bug 724632
6 years ago
6 years ago

People

(Reporter: dietrich, Assigned: evold)

Tracking

unspecified
1.15

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [MemShrink:P3])

Attachments

(1 attachment)

(Reporter)

Description

6 years ago
Created attachment 677904 [details]
screenshot

see screenshot
(Reporter)

Updated

6 years ago
Whiteboard: [memshrink]
cc'ing myself, gozala and Nicholas. While this isn;t a leak, the use of traits seems to cause egregious amounts of memory allocation. Traits is deprecated and has a logical successor so if it is causing issues we can bump the priority of porting various apis to use heritage.

Also, if heritage uses less, the same or more memory, would be good to know that as well.
BTW, you can copy and paste the contents of about:memory;  it's just text.
I looked for any trait.js usage in Aurora on OS X, the worst offender was a couple of MB:

──2,942,184 B (00.30%) -- compartment([System Principal], resource://transmission-web-helper-at-canuckistani-dot-ca/api-utils/lib/traits.js (from: resource://gre/modules/XPIProvider.jsm -> jar:file:///Users/jeff/Library/Application%20Support/Firefox/Profiles/b49h24eg.default/extensions/transmission-web-helper@canuckistani.ca.xpi!/bootstrap.js -> resource://transmission-web-helper-at-canuckistani-dot-ca/api-utils/lib/loader.js:143))

I'm betting this is related to that add-on's use of the context-menu module, which has been reimplemented on master.

Dietrich, anything unusual about your setup ( running the app for ages, etc ) that might allow these compartments to accrue tons of RAM?

I installed memchaser and started logging, the memory usage of that compartment is currently:

─678,328 B (00.07%) -- compartment([System Principal], resource://memchaser-at-quality-dot-mozilla-dot-org/api-utils/lib/traits.js (from: resource://memchaser-at-quality-dot-mozilla-dot-org/api-utils/lib/loader.js:137))

Logging is enabled, and perhaps there is a steady memory leak as logging continues?
Whiteboard: [memshrink] → [MemShrink]
> I installed memchaser and started logging, the memory usage of that compartment is 
> currently:

We've had so many problems with MemChaser itself leaking memory (either directly or via the SDK) that I can't recommend using MemChaser for any sort of testing.  I recommend using your system's equivalent of top instead.
Summary: traits.js is 15mb memory for each instance → JetPack's traits.js is 15mb memory for each instance
Summary: JetPack's traits.js is 15mb memory for each instance → Jetpack's traits.js is 15mb memory for each instance
Whiteboard: [MemShrink] → [MemShrink:P3]
Priority: -- → P1
Assignee: nobody → evold
Depends on: 724632
I wonder if this was related to bug 833783
OS: Mac OS X → All
Hardware: x86 → All
Target Milestone: --- → 1.15
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 724632
You need to log in before you can comment on or make changes to this bug.