[Webkit-unassigned] [Bug 72404] Could save a lot of memory in CharacterData by not always storing a String

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Nov 30 16:45:56 PST 2011


https://bugs.webkit.org/show_bug.cgi?id=72404





--- Comment #8 from Erik Arvidsson <arv at chromium.org>  2011-11-30 16:45:55 PST ---
I started looking at this and I hit the limitation of my C++ knowledge.

To make this worth it, it seems like we would need to use a union type. However, union types cannot have POD members.

I talked to Jeffrey Yasskin (C++ guru at Google) and he pointed me to the ManualConstructor pattern (BSD licensed):

http://code.google.com/p/google-ctemplate/source/browse/trunk/src/base/manual_constructor.h

Does WTF have anything similar? If not, can we add something like it? (Preferably a port of the GTL code since according to Jeffrey it is very hard to get this right).

Maybe I'm missing something and there is a simpler way to do this?

Also, when testing this I used ActivityMonitor. What is a better tool to see the memory usage of this?

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list