lkml.org 
[lkml]   [2014]   [Apr]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [PATCH] lib/spinlock_debug: Tweak the loop time to fit different _delay()
Date
Hello Peter,

> -----Original Message-----
> From: Peter Zijlstra [mailto:peterz@infradead.org]
> Sent: Wednesday, April 30, 2014 4:55 PM
> To: Wang, Xiaoming
> Cc: mingo@redhat.com; linux-kernel@vger.kernel.org; Liu, Chuansheng
> Subject: Re: [PATCH] lib/spinlock_debug: Tweak the loop time to fit different
> _delay()
>
> On Wed, Apr 30, 2014 at 06:40:38PM -0400, Wang, Xiaoming wrote:
> > loops_per_jiffy*Hz is not always 1 second exactly
> > it depends on the realization of _delay() .
> > delay_tsc is used as _delay() in arch/x86/lib/delay.c
>
> This just states delay() is broken. The primary response should be to
> try and fix that, no?


delay(1s_count) is accurate, but delay(1) is not accurate indeed, since executing
some instruction, then the 1 cycle delay maybe be used already.



\
 
 \ /
  Last update: 2014-05-01 05:21    [W:0.084 / U:0.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site