public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Eric Wong <e@80x24.org>
To: Dmitry Banschikov <me@ubique.spb.ru>
Cc: linux-kernel@vger.kernel.org,
	John Stultz <john.stultz@linaro.org>,
	Deepa Dinamani <deepa.kernel@gmail.com>
Subject: Re: epoll_wait inaccurate timeout
Date: Mon, 12 Dec 2016 11:34:01 +0000	[thread overview]
Message-ID: <20161212113401.GA25817@starla> (raw)
In-Reply-To: <CABuNDZTctuL_m31bYTK5XjrEO-CtYM07xOBoZWBcgcTgM5qE_Q@mail.gmail.com>

+Cc folks who may know about timer stuff on epoll.

Dmitry Banschikov <me@ubique.spb.ru> wrote:
> Hi!
> 
> I have a problem caused by inaccurate timeouts in epoll_wait(2).
> Here are some parts of strace -tt output:

Which kernel version are you using?

> 22578 09:33:46.959791 epoll_wait(5,  <unfinished ...>
> 22578 09:33:50.010794 <... epoll_wait resumed> [], 128, 1498) = 0
> ...
> 22034 09:35:07.686896 epoll_wait(5,  <unfinished ...>
> 22034 09:35:09.482526 <... epoll_wait resumed> [{EPOLLIN,
> {u32=151458248, u64=151458248}}], 128, 362) = 1
> ...
> 22036 09:35:41.433241 epoll_wait(5,  <unfinished ...>
> 22036 09:35:43.176881 <... epoll_wait resumed> [], 128, 97) = 0
> 
> In each example epoll_wait is blocked for too longer then asked in timeout.
> 
> Is it normal?

I don't think so, unless you have a huge /proc/<pid>/timerslack_ns
set.  But I mainly use -1 or 0 as the timeout value.

> Please CC me.

That's standard procedure, here :)

  reply	other threads:[~2016-12-12 11:41 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-02 12:11 epoll_wait inaccurate timeout Dmitry Banschikov
2016-12-12 11:34 ` Eric Wong [this message]
2016-12-13  7:47   ` Dmitry Banschikov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161212113401.GA25817@starla \
    --to=e@80x24.org \
    --cc=deepa.kernel@gmail.com \
    --cc=john.stultz@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=me@ubique.spb.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox