Bug 46691 - [EFL] Use fast malloc for WebKit EFL
Summary: [EFL] Use fast malloc for WebKit EFL
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit EFL (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC Linux
: P2 Normal
Assignee: Nobody
Depends on:
Reported: 2010-09-27 19:58 PDT by Gyuyoung Kim
Modified: 2010-10-04 20:38 PDT (History)
7 users (show)

See Also:

Patch (2.29 KB, patch)
2010-09-27 22:23 PDT, Gyuyoung Kim
no flags Details | Formatted Diff | Diff
Patch (2.31 KB, patch)
2010-09-29 00:19 PDT, Gyuyoung Kim
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Gyuyoung Kim 2010-09-27 19:58:47 PDT
FastMalloc is to allocate memory quickly. I think we need to use fast malloc as well.
Comment 1 Gyuyoung Kim 2010-09-27 22:23:00 PDT
Created attachment 69021 [details]
Comment 2 Lucas De Marchi 2010-09-28 04:37:44 PDT
Looks good to me. However I wonder how fast it is. Does anyone have some benchmarks? Do other ports use it by default?
Comment 3 Gyuyoung Kim 2010-09-28 18:41:30 PDT
WebKit-GTK uses the fast malloc. However, android port, brewmp port and HAIKU port don't use it. I don't know if mac port, iphone use the fast malloc.

According to QT port guys in seged univ, fast malloc based on TCMalloc is about 2 ~ 4% faster than system malloc.


In addition, the fast malloc is good for multi-thread environment. Because, TCMalloc in the fast malloc has thread local cache per thread.

Comment 4 Zoltan Horvath 2010-09-29 00:05:52 PDT
Comment on attachment 69021 [details]

View in context: https://bugs.webkit.org/attachment.cgi?id=69021&action=review

Qt, Mac, Gtk, etc. ports use TCmalloc.

> cmake/OptionsEfl.cmake:57
> +WEBKIT_FEATURE(ENABLE_FAST_MALLOC "Enable fast memory allocation" DEFAULT ON)

It would be better to reflect the switching between system's default allocator and TCmalloc. 
E.g. Enable TCmalloc instead of system's allocator
Comment 5 Gyuyoung Kim 2010-09-29 00:19:48 PDT
Created attachment 69166 [details]

Ok, I change the description according to your opinion. I also think that this description reflects correct information.
Comment 6 Gyuyoung Kim 2010-09-30 18:02:51 PDT
Hello Kenneth and Antonio,

If you are not busy, could you please review this bug?
Comment 7 Adam Barth 2010-10-04 20:38:08 PDT
Comment on attachment 69166 [details]

Clearing flags on attachment: 69166

Committed r69060: <http://trac.webkit.org/changeset/69060>
Comment 8 Adam Barth 2010-10-04 20:38:14 PDT
All reviewed patches have been landed.  Closing bug.