Re: gthread: how many cores do I have?
- From: Cody Russell <bratsche gnome org>
- To: jcupitt gmail com
- Cc: gtk-devel-list gnome org
- Subject: Re: gthread: how many cores do I have?
- Date: Mon, 15 Mar 2010 16:24:55 -0500
On Mon, 2010-03-15 at 21:14 +0000, jcupitt gmail com wrote:
> Yes, libdispatch is a nice mechanism. If anyone's not come across it,
> it provides dynamically resizeable threadpools with a central manager
> which adjusts pools globally to keep the system from bogging down (and
> a few other bells and whistles, or that's my understanding anyway).
>
> But it seems to me that we have a more immediate need: gthread has a
> threadpools, but no way to pick a reasonable size for a pool.
>
> I guess existing cross-platform applications and libraries which use
> threadpools must all have some duplicated code to pick a default pool
> size*. If we centralise this, we could perhaps add some standard
> mechanisms, like a --g-threadpool-size=N argument, or a
> G_THREADPOOL_SIZE environment variable.
Not sure if you've seen this, but Christian Hergert has an interesting
library called iris that includes thread and task scheduling.
http://git.dronelabs.com/iris
/ Cody
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]