From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (qmail 5923 invoked from network); 19 Jan 2000 16:53:46 -0000 Received: from mail.redhat.com (199.183.24.239) by lists.redhat.com with SMTP; 19 Jan 2000 16:53:46 -0000 Received: from paralleldata.com (smtp.paralleldata.com [38.153.145.2]) by mail.redhat.com (8.8.7/8.8.7) with ESMTP id LAA16469 for ; Wed, 19 Jan 2000 11:53:42 -0500 Received: by paralleldata.com from localhost (router,SLMail V2.5); Wed, 19 Jan 2000 10:59:14 -0600 Received: by paralleldata.com from paralleldata.com (24.15.240.182::mail daemon; unverified,SLMail V2.5); Wed, 19 Jan 2000 10:59:11 -0600 Sender: "Wsb" Message-ID: <3885E9FE.ACCFEFEF@paralleldata.com> Date: Wed, 19 Jan 2000 10:44:46 -0600 From: "Wes Bauske" Organization: Parallel Data Systems Inc. X-Mailer: Mozilla 4.51 [en] (X11; I; Linux 2.2.5-15 i686) X-Accept-Language: en MIME-Version: 1.0 To: axp-list@redhat.com Subject: Re: Force app to use single CPU References: <15AD5D7936F8D21198240000F831776E3E812B@dboexc1.dbo.cpqcorp.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit "Jakma, Paul" wrote: > > > that seems to spend a lot of time context > > switching between > > the processors (judging from xosview). > > or maybe a case of the observed system being influenced by the measuring > tool? > > ie xosview needs cpu time aswell. (and quite a lot of it). > > consider the unobserved system, where your app and the X server are the main > loads. The linux scheduler will correctly try to keep X on one cpu, and your > app on the other. > > Now introduce xosview. You have 3 processes fighting for cpu_time, and only > 2 cpu's. The linux scheduler will still try maintain cpu affinity, but if a > cpu becomes free, there's no point in wasting that slot. > > what you are seeing is correct scheduler behaviour. > Using affinity though, if the scheduler weights things reasonably, would put the cpu constrained task on one cpu and leave it there while putting things like X/xosview/your favorite window manager/the clock/xterms/etc. on the other. If you want to look at a minimally cluttered environment, run things from a text screen, not X. If your program needs X, maybe you should separate the compute part from the display part. (Works for me... YMMV) Wes