From owner-freebsd-smp@FreeBSD.ORG Fri Feb 23 15:42:28 2007 Return-Path: X-Original-To: freebsd-smp@freebsd.org Delivered-To: freebsd-smp@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 360F216A400 for ; Fri, 23 Feb 2007 15:42:28 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from cyrus.watson.org (cyrus.watson.org [209.31.154.42]) by mx1.freebsd.org (Postfix) with ESMTP id 0F07D13C467 for ; Fri, 23 Feb 2007 15:42:28 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from fledge.watson.org (fledge.watson.org [209.31.154.41]) by cyrus.watson.org (Postfix) with ESMTP id 197B04759D; Fri, 23 Feb 2007 10:13:53 -0500 (EST) Date: Fri, 23 Feb 2007 15:13:52 +0000 (GMT) From: Robert Watson X-X-Sender: robert@fledge.watson.org To: "Kunze, Aaron" In-Reply-To: <07DDDFCFB8BE0A43BCA52E743373DBDC030C5D5A@orsmsx416.amr.corp.intel.com> Message-ID: <20070223151158.Q88189@fledge.watson.org> References: <07DDDFCFB8BE0A43BCA52E743373DBDC030C5D5A@orsmsx416.amr.corp.intel.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: atmblr@gmail.com, freebsd-smp@freebsd.org Subject: Re: Setting CPU affinity to process( Freebsd smp kernel) X-BeenThere: freebsd-smp@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD SMP implementation group List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Feb 2007 15:42:28 -0000 On Wed, 21 Feb 2007, Kunze, Aaron wrote: > Does anyone know if this will change any time soon? For example, is anyone > working on exposing affinity to user-space applications via extensions of > the pthreads interface? > > Sorry to reply to such an old thread... I know of no work along these lines currently, but it's something a lot of people would like to see happen. There's a potential for conflict between the kernel's use of pinning and binding for kernel synchronization and the user space affinity model, which will be entirely avoided if done right. :-) For now, it's quite easy to add a sysctl/syscall that allows user space to send the kernel scheduler's notion of thread binding, but this isn't really the right approach. As I understand it, some systems support setting CPU affinity for a thread as a set of CPUs it is willing to run on ? Robert N M Watson Computer Laboratory University of Cambridge > > Aaron > > --------------- > > On Monday 20 November 2006 06:24, Ashok TM wrote: >> Hello, >> >> Is there a way to set a process's CPU affinity with freebsd smp > kernel. >> By doing so a process is bound to and will only run on the processor > (where >> the affinity was set ) even though the other processors are free. > (similar >> to sched_setaffinity available on Linux kernel) . >> >> Does freebsd smp scheduler supports setting affinity? > > Yes, but currently only in the kernel. > > -- > John Baldwin > > > -------------------------- > Aaron Kunze > aaron.kunze@intel.com > --PGP Key ID: 0x81124B7C-- > --NOT SPEAKING FOR INTEL-- > -------GO BOILERS!!------- > > _______________________________________________ > freebsd-smp@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-smp > To unsubscribe, send any mail to "freebsd-smp-unsubscribe@freebsd.org" >