Re: ideas for returning memory to the OS
Brian Crowder <[email protected]> Tue, 11 Dec 2007 15:15:01 -0800 (PST)
| Newsgroups | gmane.comp.mozilla.performance |
|---|---|
| Organization | http://groups.google.com |
| Message-ID | <[email protected]> |
> > roc's suggestion in this thread is that each of the different > > platforms has a specific means of hinting that a page is ready > > for reuse, and that we should (on each platform individually) > > use those hinting procedures to improve our performance (with > > respect to memory utilization). > > Right. But all this should happen within (and hidden behind the > interfaces of) some dedicated memory management library. > So maybe lets call it "libnewmalloc" and all the moz code > would now use libnewmalloc's functions instead of libc's. > And this lib won't be directly included within the moz tree, > but instead *imported*. No, each different piece of mozilla manages objects or structures with different life-spans and performance constrains, usage-patterns, and so on. Optimal performance means tuning these chunks of the mozilla code individually, NOT us writing our own general purpose allocator. Your suggested libnewmalloc would either be large and complex, itself (because of the complexity involved in providing generic solutions to specific problems), or fail to achieve its goal (specialized tuning) while adding yet another layer of indirection. -- crowder