Make sure the gc-heap memory reporter is in the right place

RESOLVED FIXED

Status

()

Core
XPConnect
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: njn, Assigned: njn)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

6 years ago
Created attachment 531833 [details] [diff] [review]
patch

If MOZ_MEMORY is undefined then the GC heap is allocated with mmap instead of malloc.  But the GC heap memory reporter always has the path "heap-used/js/string-data" which means that when MOZ_MEMORY is undefined it'll put it in the wrong place.

This patch fixes this problem.
Attachment #531833 - Flags: review?(anygregor)
(Assignee)

Comment 1

6 years ago
I can confirm that on Mac, MOZ_MEMORY is undefined (because it doesn't use jemalloc) and so the GC heap space was incorrectly categorized as being on the (malloc) heap.  The patch moves it to the right place:

Mapped Memory
2,920.00 MB (100.0%) -- mapped
├──2,868.40 MB (98.23%) -- other
├─────44.17 MB (01.51%) -- heap
│     ├──29.27 MB (01.00%) -- used
│     └──14.90 MB (00.51%) -- unused
└──────7.44 MB (00.25%) -- js
       ├──7.00 MB (00.24%) -- gc-heap
       ├──0.44 MB (00.01%) -- mjit-code
       └──0.00 MB (00.00%) -- (1 omitted)
Attachment #531833 - Flags: review?(anygregor) → review+
(Assignee)

Comment 2

6 years ago
http://hg.mozilla.org/mozilla-central/rev/344bddedf5b3
Status: ASSIGNED → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.