Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 26 Feb 2005 18:13:08 +1100
From:      Peter Jeremy <PeterJeremy@optushome.com.au>
To:        freebsd-stable@freebsd.org
Subject:   Excessive delays due to syncer kthread
Message-ID:  <20050226071308.GN57256@cirb503493.alcatel.com.au>

next in thread | raw e-mail | index | archive | help
I am trying to do some video capture and have been losing occasional
fields.  After adding some debugging code to the kernel, I've found
that the problem is excessive latency between the hardware interrupt
and the driver interrupt - the hardware can handle about 1.5msec of
latency.  Most of the time, the latency is less than 20µsec but but
I'm seeing up to 8 msec occasionally.  In virtually all cases where
there is a problem, curproc at the time of the hardware interrupt is
syncer.  (I had one case where there was another process, but it had
died by the time I went looking for it).  The interrupt is marked
INTR_TYPE_AV so it shouldn't be being delayed by other threads.  (I
can't easily make it INTR_FAST because it needs to call psignal(9)).

The system is an Athlon XP-1800 with 512MB RAM and 2 ATA-100 disks
running 5.3-RELEASE-p5.  It has a couple of NFS exports but doesn't
import anything.  There's nothing much running apart from ffmpeg
capturing the video and a process capturing my kernel debugging
output.  Apart from 4 files being sequentially written as part of my
capture and cron regularly waking up to go back to sleep, there
shouldn't be any filesystem activity.  I tried copying a couple of
large files and touching lots of files but that didn't cause any
problems.

Can anyone suggest why syncer would be occasionally running for
up to 8 msec at a time?  Overall, it's not clocking up a great
deal of CPU time, it just seems to grab it in large chunks.

Peter



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050226071308.GN57256>