"Musical chairs" zeal mode for malloc memory
Categories
(Core :: JavaScript: GC, enhancement, P3)
Tracking
()
People
(Reporter: sfink, Unassigned)
References
(Blocks 1 open bug)
Details
We could have a compacting zeal mode that intentionally moves everything around in memory on every GC.
Comment 1•3 years ago
|
||
We already move everything for zeal mode shrinking GCs, unless there's something more we can do:
https://searchfox.org/mozilla-central/source/js/src/gc/Compacting.cpp#132-134
Reporter | ||
Comment 2•3 years ago
|
||
(In reply to Jon Coppeard (:jonco) from comment #1)
We already move everything for zeal mode shrinking GCs, unless there's something more we can do:
Oh, you're right. At one of our meetings, maybe a month or two ago, we discussed something called "musical chairs" zeal mode and you asked me to file a bug for it. I stumbled across a note telling me to file the bug, but I couldn't remember exactly what it was about.
I think I remember. I think this was for moving around malloc memory hanging off of GC things. In particular, I think it came up in the context of strings and/or ArrayBuffer data. Gecko does some sketchy stuff with stashing away ArrayBuffer data pointers, and might be getting away with it most of the time because 99% of the time it's a tenured, non-inline ABO.
Comment 3•3 years ago
|
||
(In reply to Steve Fink [:sfink] [:s:] from comment #2)
I think I remember. I think this was for moving around malloc memory hanging off of GC things. In particular, I think it came up in the context of strings and/or ArrayBuffer data. Gecko does some sketchy stuff with stashing away ArrayBuffer data pointers, and might be getting away with it most of the time because 99% of the time it's a tenured, non-inline ABO.
Good idea! I had forgotten about this.
Updated•3 years ago
|
Description
•