[webkit-dev] fastMallloc
Mark Rowe
mrowe at apple.com
Thu Jul 24 13:06:01 PDT 2008
On Jul 24, 2008, at 7:32 AM, Balázs Kelemen wrote:
> Hi Webkit developers!
>
> I would ask you about the use of the tcmalloc system. I believed
> that it is the default malloc system under Webkit. But when I
> browsed the code, I had realized that if the USE_SYTEM_MALLOC
> directive is set, operator new and operator delete doesn't
> overridden by fastMalloc and fastFree, and that case fastMalloc and
> fastFree calls malloc and free. It is the standard malloc and free?
> Moreover I can't find any definition of this functions in the case
> when USE_SYSTEM_MALLOC isn' set. In my system -I work with the Qt
> port on Linux in the team of University Szegediensis- the Makefiles
> contain -DUSE_SYSTEM_MALLOC in release and debug builds too.
If USE_SYTEM_MALLOC is defined then, as its name suggests, the system
malloc implementation will be used. I believe that the Qt port always
uses the system allocator as there is no portable method of
restricting the scope of global operator new to a single library, and
they did not wish WebKit's custom allocator to interfere with Qt
client applications.
- Mark
More information about the webkit-dev
mailing list