Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 22 Jan 2013 10:42:21 -0800
From:      Adrian Chadd <adrian@freebsd.org>
To:        Daniel Braniss <danny@cs.huji.ac.il>
Cc:        freebsd-stable@freebsd.org, Ian Lepore <ian@freebsd.org>
Subject:   Re: time issues and ZFS
Message-ID:  <CAJ-VmokQbZFGmmy=KkEmP%2B7a6DQRGhdgupqF4sNCGJYxvA-B0g@mail.gmail.com>
In-Reply-To: <E1TxaZv-0005fj-5m@kabab.cs.huji.ac.il>
References:  <E1TxFcr-0006dx-MX@kabab.cs.huji.ac.il> <1358780588.32417.414.camel@revolution.hippie.lan> <E1TxJP2-000DS8-DJ@kabab.cs.huji.ac.il> <1358783667.32417.434.camel@revolution.hippie.lan> <CAJ-Vmo=2Dmf4Lb-uoUQDrybyRSS=_bnV5KcNYGg5MnMxfhhu7w@mail.gmail.com> <E1TxYHa-0002yo-4Y@kabab.cs.huji.ac.il> <CAJ-VmomdQORjs55ooW55Rgg0i1M13PPtnmCPRrp__btEWQz=4g@mail.gmail.com> <E1TxaZv-0005fj-5m@kabab.cs.huji.ac.il>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi!

As I said before, the problem with non-HLT loops with event-timer in
-9 and -head is that it calls the idle function inside a critical
section (critical_enter and critical_exit) which blocks interrupts
from occuring.

The EI;HLT instruction pair on i386/amd64 atomically and correctly
handles things from what I've been told.

However, there's no atomic way to do this using ACPI sleeping, so
there's a small window where an interrupt may come in but it isn't
handled; waiting for the next interrupt to occur before it'll wake up
and respond to that interrupt.

I kept hitting my head against this when doing network testing. :(

Now - specifically for timekeeping it shouldn't matter; that's to do
with whether the counters are reliable or not (and heck, are even in
lock-step on CPUs.) But extra latency could show up weirdly, hence why
I was asking for you to try different timer configurations and idle
loops.

Thanks,


Adrian

On 22 January 2013 01:55, Daniel Braniss <danny@cs.huji.ac.il> wrote:
>> Daniel,
>>
>> Have you run tests with the machdep.idle value changed, and fiddling
>> kern.eventtimer.periodic / kern.eventtimer.idletick ?
>
> Adrian,
>
> not yet, for several reasons:
> 1- as I explained, I can't realy force the problem, it happens when we run some
> zfs scripts, like mirror, but have to wait till enough changes happened on
> the source, usualy after 24hs.
> 2- changing to LAPIC seems to have solved the problem.
> 3- I'm now learning all I can about event timers and you have not answered some
>    of my questions :-)
>
> danny
>
>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAJ-VmokQbZFGmmy=KkEmP%2B7a6DQRGhdgupqF4sNCGJYxvA-B0g>