Closed Bug 1134754 Opened 10 years ago Closed 10 years ago

Only compact zones where we can reclaim a useful amount of memory

Categories

(Core :: JavaScript: GC, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla39
Tracking Status
firefox39 --- fixed

People

(Reporter: jonco, Assigned: jonco)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

At the moment we compact all zones that we collect in a shrinking GC. However this is wasteful, because we may not be able to free much or any memory at all. We should skip compacting zones if we cannot free up a certain proportion of their allocated memory.
Attached patch skip-unnecessary-compaction (deleted) — Splinter Review
This patch calculates the number of arenas that we are going to free up for each zone before deciding whether to compact or skip that zone. The decision is based on the GC reason so that OOM or memory pressure GCs will free up all possible memory. Otherwise we only compact if we can free at least 2% of the zone's GC heap memory (I made this number up so tuning may be required).
Attachment #8567100 - Flags: review?(terrence)
Attachment #8567100 - Flags: review?(terrence) → review+
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla39
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: