On Fri, 22 Mar 2013 12:52:19 -0400 Matthew Mondor <mm_li...@pulsar-zone.net> wrote:
> On Fri, 22 Mar 2013 11:46:16 +0530 > Vijay Mathew <vijay.the.lis...@gmail.com> wrote: > > > Is there a function in ECL to find the number of processors? > > Not that I know, although it's often a good idea to provide a > configuration knob such that the user of the software can decide how > many threads to use. > > If we want to add such functionality, it's OS-specific, but it seems > that today several systems support sysconf(3) with _SC_NPROCESSORS_CONF > and _SC_NPROCESSORS_ONLN (I just verified on NetBSD and Linux though). I forgot to mention it, but another complexity is that thread to CPU affinity configuration is also OS-specific. Several systems appear to support pthread_setaffinity_np(3) but it's an unofficial extension (hence the _np suffix). The interface to manipulate cpuset_t also appears to vary (I have cpuset(3) on NetBSD and cpuset(7) on Linux, and they differ). -- Matt ------------------------------------------------------------------------------ Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_d2d_mar _______________________________________________ Ecls-list mailing list Ecls-list@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ecls-list