Ok the straces do seem to tell the story; they follow below:
for the case where is the kernel is patched and NO_HZ enabled,
waitpid(3989, [{WIFSTOPPED(s) && WSTOPSIG(s) == 133}], WSTOPPED) = 3989
gettimeofday({1192649136, 409637}, NULL) = 0
gettimeofday({1192649136, 409698}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 90000}}, NULL) =
0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 91986}}) = 0
nanosleep({0, 91986000}, {0, 91986000}) = 0
gettimeofday({1192649136, 502142}, NULL) = 0
gettimeofday({1192649136, 502201}, NULL) = 0
gettimeofday({1192649136, 502260}, NULL) = 0
gettimeofday({1192649136, 502352}, NULL) = 0
gettimeofday({1192649136, 502410}, NULL) = 0
gettimeofday({1192649136, 502481}, NULL) = 0
gettimeofday({1192649136, 502578}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 10000}}, NULL) =
0
gettimeofday({1192649136, 502750}, NULL) = 0
gettimeofday({1192649136, 502814}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 290000}}, NULL)
= 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 291955}}) = 0
nanosleep({0, 291955000}, {0, 291955000}) = 0
gettimeofday({1192649136, 795308}, NULL) = 0
gettimeofday({1192649136, 795368}, NULL) = 0
gettimeofday({1192649136, 795427}, NULL) = 0
gettimeofday({1192649136, 795486}, NULL) = 0
gettimeofday({1192649136, 795544}, NULL) = 0
gettimeofday({1192649136, 795616}, NULL) = 0
gettimeofday({1192649136, 795675}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 10000}}, NULL) =
0
gettimeofday({1192649136, 795815}, NULL) = 0
gettimeofday({1192649136, 795876}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={1, 700000}}, NULL)
= 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={1, 701741}}) = 0
nanosleep({1, 701741000}, {1, 701741000}) = 0
for the case where the kernel is patched, but NO_HZ is __not__ enabled,
there is a do_nanosleep() every 100 or so us.
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 0}}) = 0
nanosleep({0, 0}, {0, 0}) = 0
gettimeofday({1192648953, 436325}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 0}}) = 0
nanosleep({0, 0}, {0, 0}) = 0
gettimeofday({1192648953, 436434}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 0}}) = 0
nanosleep({0, 0}, {0, 0}) = 0
gettimeofday({1192648953, 436532}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 0}}) = 0
nanosleep({0, 0}, {0, 0}) = 0
gettimeofday({1192648953, 436629}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 0}}) = 0
nanosleep({0, 0}, {0, 0}) = 0
gettimeofday({1192648953, 436725}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 0}}) = 0
nanosleep({0, 0}, {0, 0}) = 0
gettimeofday({1192648953, 436822}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 0}}) = 0
nanosleep({0, 0}, {0, 0}) = 0
gettimeofday({1192648953, 436919}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 0}}) = 0
nanosleep({0, 0}, {0, 0}) = 0
gettimeofday({1192648953, 437015}, NULL) = 0
setitimer(ITIMER_VIRTUAL, {it_interval={0, 0}, it_value={0, 0}},
{it_interval={0, 0}, it_value={0, 0}}) = 0
nanosleep({0, 0}, {0, 0}) = 0
Regards,
Hrishikesh
On 10/17/07, Jeff Dike <jdike@...> wrote:
>
> On Wed, Oct 17, 2007 at 12:16:18PM -0400, Hrishikesh wrote:
> > This is when I patch the UML kernel with the NO_HZ patches that you put
> up
> > last month.. on 2.6.23-rc6-mm1.
>
> Hmmm, that's exactly the opposite of what I would expect. A idle
> non-NO_HZ UML should be waking up 100 times/sec, while I see much
> longer sleeps with an idle NO_HZ UML, up to 2-3 seconds.
>
> Can you strace both cases and see how often the NO_HZ UML is waking up
> compared to the non-NO_HZ one?
>
> Jeff
>
> --
> Work email - jdike at linux dot intel dot com
>
|