[Webkit-unassigned] [Bug 30822] Change NativeImagePtr definition for wx port

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Nov 5 16:16:45 PST 2009


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





--- Comment #3 from Kevin Ollivier <kevino at theolliviers.com>  2009-11-05 16:16:45 PDT ---
(In reply to comment #2)
> I didn't measure this (it's difficult to see how to do it even remotely
> accurately) but I'd expect the extra heap allocations to have noticeable effect
> on performance so this change has more merits than just making the code more
> sensible.
> 
> I'd also like to mention that CE port already uses a class (smart pointer class
> but still) for this type so wx code wouldn't be the only exception. Of course,
> there is the difference that CE NativeImagePtr can still be implicitly
> constructed from NULL and converted to bool but realistically failing to use
> NativeImagePtr() instead of NULL in common code can't remain unnoticed for long
> as it would immediately break wxWebKit build.
> 
> Anyhow, I wonder if it's worth measuring performance gain from this change or
> if it's not going to change your decision in any case?

I'm always interested in comparing performance of different approaches, if you
feel there's a real, significant performance gain to be had here. Note though
that the average web page probably will not have more than a couple dozen
images attached to it, though, so even though heap allocation is more
expensive, I'm not sure that we're doing it so often that the hits will add up
to anything really noticeable. Also, the tests of this should probably happen
once we get the fastMalloc issue resolved, as obviously that affects
performance as well.

-- 
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