Re: [uml-devel] [2.6.24.x] UML select()/poll() oversleeping reproducibly

2008-03-19 Thread Nix
On 18 Mar 2008, Jeff Dike told this: > This version keeps track of the time between ticks (as reported by the > host's gettimeofday) and adjusts its sleeping and reporting ticks > accordingly. I can confirm that, as expected, this patch works well enough that timing problems don't break dhclient a

Re: [uml-devel] [2.6.24.x] UML select()/poll() oversleeping reproducibly

2008-03-18 Thread Nix
On 18 Mar 2008, Jeff Dike outgrape: > Below is another patch. > > I was hurt and disappointed by your >> Eew. :) > so I got rid of the 9/10 thing. Yay! That's much less dependent on the exact nature of whatever the underlying bug is :) a random 9/10, well, it just makes my skin itch even if i

Re: [uml-devel] [2.6.24.x] UML select()/poll() oversleeping reproducibly

2008-03-18 Thread Jeff Dike
Below is another patch. I was hurt and disappointed by your > Eew. :) so I got rid of the 9/10 thing. This version keeps track of the time between ticks (as reported by the host's gettimeofday) and adjusts its sleeping and reporting ticks accordingly. It's still undersleeping a little - your

Re: [uml-devel] [2.6.24.x] UML select()/poll() oversleeping reproducibly

2008-03-17 Thread Nix
On 17 Mar 2008, Jeff Dike verbalised: > Below is the same patch with another kluge, which cuts down the > requested sleep by 10% in hopes of getting the actual sleep closer to > what's wanted. Eew. :) > This is unusable in anything resembling mainline, but I'd like to see > how your various

Re: [uml-devel] [2.6.24.x] UML select()/poll() oversleeping reproducibly (was Re: g_timeout_add)

2008-03-17 Thread Jeff Dike
Below is the same patch with another kluge, which cuts down the requested sleep by 10% in hopes of getting the actual sleep closer to what's wanted. This is unusable in anything resembling mainline, but I'd like to see how your various systems react to it. I'm getting very close to the sleeps I a

Re: [uml-devel] [2.6.24.x] UML select()/poll() oversleeping reproducibly (was Re: g_timeout_add)

2008-03-17 Thread Jeff Dike
On Fri, Mar 14, 2008 at 11:01:35PM +, Nix wrote: > bash-3.2# ./select-sleep 10 > Slept for 13 seconds. See what kind of difference the patch below makes - it reduces the 30% oversleeping down to 10% for me. That's still way too much, but it's better. The problem being fixed here is that seti

Re: [uml-devel] [2.6.24.x] UML select()/poll() oversleeping reproducibly (was Re: g_timeout_add)

2008-03-17 Thread Jeff Dike
On Fri, Mar 14, 2008 at 11:01:35PM +, Nix wrote: > On a 1.4GHz Athlon IV using the tsc clocksource, I see consistent > oversleeps, but not enormous ones: > bash-3.2# ./select-sleep 10 > Slept for 13 seconds. I'm seeing the same thing with tickless disabled on current UML - stay tuned...

[uml-devel] [2.6.24.x] UML select()/poll() oversleeping reproducibly (was Re: g_timeout_add)

2008-03-14 Thread Nix
On 15 Feb 2008, Jeff Dike told this: > The smoking gun - a poll that should have timed out in .5 sec slept > for 12. FWIW this breaks all sorts of things, as one might expect: obviously it breaks select() as well as poll(). For me the symptoms were a failure of DHCP and spontaneous dropping off th