[webkit-dev] WebKit memory management?

Darin Adler darin at apple.com
Wed Jun 4 09:15:30 PDT 2008


On Jun 3, 2008, at 7:58 PM, Paul Pedriana wrote:

> The application should be able to set aside a block of RAM and have  
> the library use that block of RAM via a user-supplied memory  
> allocator. At no time should the library attempt to use any other  
> memory nor use its own means to access the user-provided memory.  
> This pattern of library development is very important, and most  
> professional commercial library software follows this pattern  
> (including all commercial peers of WebKit). I am wondering how I  
> might achieve this with WebKit.

Here's how:

     1) Change the <wtf/FastMalloc.cpp> source file to invoke this  
memory allocator instead of TCMalloc.
     2) Let us know about any concrete problems you encounter where  
that allocator isn't used, and we'll help you fix them and investigate  
putting those fixes in the WebKit trunk too.

Good luck!

     -- Darin



More information about the webkit-dev mailing list