[Webkit-unassigned] [Bug 151391] [GLIB] Implement garbage collector timers

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Nov 19 00:51:09 PST 2015


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

--- Comment #9 from Zan Dobersek <zan at falconsigh.net> ---
Comment on attachment 265749
  --> https://bugs.webkit.org/attachment.cgi?id=265749
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=265749&action=review

>>> Source/JavaScriptCore/heap/EdenGCActivityCallback.cpp:33
>>> +#if USE(CF) || USE(GLIB)
>> 
>> Is USE(GLIB) also true for EFL? I wonder if it wouldn't be better to be more explicit here for the sake of code readability and leave this as:
>> 
>> #if USE(CF) || PLATFORM(EFL) || USE(GLIB)
> 
> Yes, it's true.

Why USE(GLIB) then? It's true for both EFL and GTK, but the implementations of HeapTimer differ for the two ports.

Since all these classes are based on HeapTimer, I think the PLATFORM(EFL) || PLATFORM(GTK) should be used throughout this patch, instead of bundling them under USE(GLIB).

> Source/JavaScriptCore/heap/HeapTimer.cpp:41
>  #if PLATFORM(EFL)
>  #include <Ecore.h>
> +#elif USE(GLIB)
> +#include <glib.h>
>  #endif

Just one example, you end up doing this. It's counter-intuitive because PLATFORM(EFL) falls under USE(GLIB), but you still have to special-case it because of the different implementations.

> Source/JavaScriptCore/heap/HeapTimer.cpp:174
> +    g_source_attach(m_timer.get(), g_main_context_get_thread_default());

As it stands these timers only fire on main threads, since worker threads aren't run via a main loop.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20151119/d35ba37e/attachment.html>


More information about the webkit-unassigned mailing list