Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Wed, 10 Apr 2002 00:42:47 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Wed, 10 Apr 2002 00:42:46 -0400 Received: from 202-77-223-23.outblaze.com ([202.77.223.23]:54760 "EHLO testdcc.outblaze.com") by vger.kernel.org with ESMTP id ; Wed, 10 Apr 2002 00:42:45 -0400 Message-ID: <20020410044243.2916.qmail@fastermail.com> Content-Type: text/plain; charset="iso-8859-1" Content-Disposition: inline Content-Transfer-Encoding: 7bit MIME-Version: 1.0 X-Mailer: MIME-tools 5.41 (Entity 5.404) From: "mark manning" To: linux-kernel@vger.kernel.org Date: Tue, 09 Apr 2002 23:42:43 -0500 Subject: Re: nanosleep X-Originating-Ip: 67.241.61.228 X-Originating-Server: ws4.hk5.outblaze.com X-DCC-Outblaze-Metrics: testdcc.outblaze.com 100; env_From=10 From=10 Message-ID=1 Received=1 Body=2 Fuz1=2 Fuz2=2 Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org thanx - how much of a difference should i expect - i know the syscall is asking for at least the required ammount but that the task switcher might not give me control back for a while after the requested delay but i was expecting to be a little closer to what i had asked for - this isnt critical of corse but i would like to know what to expect. ----- Original Message ----- From: "H. Peter Anvin" Date: Tue, 09 Apr 2002 21:17:03 -0700 To: mark manning Subject: Re: nanosleep > mark manning wrote: > > doh - i think something is still wrong, i ask for 1000 ms and i get a second but if i do a 500 itteration loop asking for 1 ms i get 5 seconds. i am also starting to distrust my elapsed time display which is using the gettimeofday syscall > > > > It doesn't work that way. Each call to nanosleep() gives you a > *MINIMUM* time to delay. The kernel may decide to schedule you away and > pick your process up when it suits it. > > -hpa > > > -- _______________________________________________ Get your free email from http://www.fastermail.com Powered by Outblaze - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/