As I mentioned, there is a reverse of a medal, so now let's see how enabling TCmalloc on the QtWebKit port's JavaScriptCore engine effects memory consumption.

Results for x86

We can see the memory consumption results of QtWebKit on x86-Linux (with JIT) in kilobytes in the following table:

QtWebKit x86-Linux System malloc TCmalloc Difference SunSpider 12 162 kB 15 209 kB ~25.05% hungrier V8 139 513 kB 140 270 kB ~0.54% hungrier WindScorpion 34 046 kB 40 528 kB ~19.03% hungrier

SunSpider

12 162 kB -> 15 209 kB

+ 3 047 kB

~25.05% hungrier V8

139 513 kB -> 140 270 kB

+ 757 kB

~0.54% hungrier WindScorpion

34 046 kB -> 40 528 kB

+ 6 482 kB

~19.03% hungrier

Conclusion

As we can expect, TCmalloc eats more memory on all of the three benchmark suites than the system malloc. We have to pay the price for the achieved significant performance improvement with enabling it.

Future

These results represents the memory consumption of the JavaScriptCore part of the WebKit only, so in the future maybe we should investigate the results for the whole WebKit. Moreover, we have several possibilities to try decreasing the memory consumption: tweaking the parameters of TCmalloc, turning off TCmalloc :-) and trying out other allocators.