[webkit-dev] Slow idioms with WTF::String

Darin Adler darin at apple.com
Tue Jul 12 10:57:02 PDT 2011

On Jul 12, 2011, at 10:31 AM, Darin Fisher wrote:

> On Tue, Jul 12, 2011 at 10:25 AM, Darin Adler <darin at apple.com> wrote:
>> I would not be surprised if at least some of these will show up immediately with the right kind of performance test. The CSS parsing and serialization functions seem almost certain to be measurably slow.
>> I’m looking for two related things:
>>    1) A clean way to find and root out uses of the inefficient idioms that we can work on together as a team.
>>     2) Some ways to further refine WTF::String so it’s harder to “use it wrong”. I don’t have any immediate steps in mind, but one possibility would be to remove functions that are usually part of poorly-performing idioms, pushing WebKit programmers subtly in the direction of operations that don’t build intermediate strings.
> This thread resonates very deeply with me (idioms that make it hard to write slow code == pure goodness), but I suspect we really ought to build performance tests to help support these improvements. It is easy to put a lot of energy into optimizing code that provides no measurable benefit :-/

I think we are in agreement.

I think my “I would not be surprised if these show up with the right kind of performance test” comment wasn’t direct enough.

    -- Darin

More information about the webkit-dev mailing list