[Webkit-unassigned] [Bug 92365] Refactor cross thread communication

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Jul 27 00:01:51 PDT 2012


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





--- Comment #3 from Kwonjin Jeong <gram at company100.net>  2012-07-27 00:01:54 PST ---
(In reply to comment #2)
> This makes every task implement ThreadSafeRefCounted solely in order to support this
>   "Cancel a group of tasks that are pending in the task queue."
> 
> Could that be done in a different way in order to avoid this? Also, what is the scenario in which this is needed?

I can't understand your question exactly.
In my proposal, the task is just a WTF::Function instance. Implementing new class for a task isn't needed.

There are some cases canceling a group of the tasks.
AsyncFileStream::stop() method unschedules all tasks related to specific FileStream instance by calling FileThread::unscheduleTasks() method. DatabaseThread also has an API for unscheduling all tasks related to specific Database instance.


> It also looks like you're proposing getting rid of the fact that all the copying was done automatically so that people couldn't mess that up by accident. Is that true?

I don't want to get rid of it so I add CrossThreadCopyable class for automatic parameter copying.
But I have to keep the behavior of WTF::Function. For some types like WTF::String, because of that, parameters are copied manually using deepCopy() function.

Thank you for your comment.

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