[Webkit-unassigned] [Bug 125488] [GStreamer] Use g_object_notify_by_pspec in custom elements

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jan 16 10:05:49 PST 2014


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





--- Comment #7 from Brendan Long <b.long at cablelabs.com>  2014-01-16 10:03:24 PST ---
(In reply to comment #6)
> > Source/WebCore/platform/graphics/gstreamer/TextCombinerGStreamer.cpp:216
> > -        g_object_notify(G_OBJECT(pad), "tags");
> > +        g_object_notify_by_pspec(G_OBJECT(pad), padProperties[PROP_PAD_TAGS]);
> 
> This specific change doesn't seem really worth to me. Pad events don't occur that often (I think) and g_object_notify() for this object should already be quite efficient since the class has only one property.
> 
> It's true that _by_pspec is advised but I think it depends how often that code path would be used and also on the number of properties of the class.

That makes sense. The GLib documentation indicated that you should always use g_object_notify_by_pspec if you can, but I guess it doesn't really matter much in this case.

We actually do get quite a few tag events in a row while the video is loading, but the string comparison in g_object_notify probably isn't a bottleneck.

> > Source/WebCore/platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:861
> > -        g_object_notify(G_OBJECT(src), "iradio-name");
> > +        g_object_notify_by_pspec(G_OBJECT(src), properties[PROP_IRADIO_NAME]);
> 
> About this and the following ones, I think I agree with the changes. How often is handleResponseReceived called though?

I'm not really sure. I'll do some tests to see.

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