From: Peter Zijlstra <peterz@infradead.org>
To: Glauber Costa <glommer@redhat.com>
Cc: kvm@vger.kernel.org, linux-kernel@vger.kernel.org,
Rik van Riel <riel@redhat.com>,
Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>,
Avi Kivity <avi@redhat.com>,
Anthony Liguori <aliguori@us.ibm.com>,
Eric B Munson <emunson@mgebm.net>
Subject: Re: [PATCH v3 8/9] KVM-GST: adjust scheduler cpu power
Date: Thu, 30 Jun 2011 23:54:27 +0200 [thread overview]
Message-ID: <1309470867.12449.605.camel@twins> (raw)
In-Reply-To: <1309361388-30163-9-git-send-email-glommer@redhat.com>
On Wed, 2011-06-29 at 11:29 -0400, Glauber Costa wrote:
> + return __touch_steal_time(is_idle, UINT_MAX, NULL);
That wants to be ULLONG_MAX, because max_steal is a u64, with UINT_MAX
the comparison:
+ if (steal > max_steal)
Isn't true per-se and the compiler cannot optimize the branch away.
Also, make sure it does indeed optimize that branch away, otherwise
simply duplicate the code. This is on the very hottest scheduler paths,
branches do count.
Same for:
+ if (ticks)
with ticks == NULL, make sure it never emits code for the above call.
Ah, also, all that requires you strip that noinline crap you put on it,
if it cannot inline, it cannot assume anything on the input and will
this have to emit all this nonsense.
next prev parent reply other threads:[~2011-06-30 21:55 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-29 15:29 [PATCH v3 0/9] Steal time for KVM Glauber Costa
2011-06-29 15:29 ` [PATCH v3 1/9] introduce kvm_read_guest_cached Glauber Costa
2011-06-29 15:29 ` [PATCH v3 2/9] KVM-HDR Add constant to represent KVM MSRs enabled bit Glauber Costa
2011-06-29 21:56 ` Eric B Munson
2011-06-30 8:31 ` Avi Kivity
2011-06-30 12:59 ` Eric B Munson
2011-06-30 13:21 ` Glauber Costa
2011-06-30 14:13 ` Eric B Munson
2011-06-29 15:29 ` [PATCH v3 3/9] KVM-HDR: KVM Steal time implementation Glauber Costa
2011-06-29 21:56 ` Eric B Munson
2011-06-30 21:54 ` Peter Zijlstra
2011-06-29 15:29 ` [PATCH v3 4/9] KVM-HV: " Glauber Costa
2011-06-29 21:56 ` Eric B Munson
2011-06-29 15:29 ` [PATCH v3 5/9] KVM-HV: use schedstats to calculate steal time Glauber Costa
2011-06-29 21:56 ` Eric B Munson
2011-06-29 15:29 ` [PATCH v3 6/9] KVM-GST: Add a pv_ops stub for " Glauber Costa
2011-06-29 21:56 ` Eric B Munson
2011-06-29 15:29 ` [PATCH v3 7/9] KVM-GST: KVM Steal time accounting Glauber Costa
2011-06-29 21:57 ` Eric B Munson
2011-06-30 21:54 ` Peter Zijlstra
2011-07-01 2:53 ` Glauber Costa
2011-07-01 8:26 ` Peter Zijlstra
2011-06-30 21:54 ` Peter Zijlstra
2011-07-01 2:50 ` Glauber Costa
2011-06-30 21:54 ` Peter Zijlstra
2011-07-01 2:50 ` Glauber Costa
2011-07-01 8:25 ` Peter Zijlstra
2011-06-30 21:54 ` Peter Zijlstra
2011-06-29 15:29 ` [PATCH v3 8/9] KVM-GST: adjust scheduler cpu power Glauber Costa
2011-06-29 21:57 ` Eric B Munson
2011-06-30 21:54 ` Peter Zijlstra
2011-06-30 21:54 ` Peter Zijlstra [this message]
2011-06-30 21:54 ` Peter Zijlstra
2011-06-29 15:29 ` [PATCH v3 9/9] KVM-GST: KVM Steal time registration Glauber Costa
2011-06-29 21:57 ` Eric B Munson
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=1309470867.12449.605.camel@twins \
--to=peterz@infradead.org \
--cc=aliguori@us.ibm.com \
--cc=avi@redhat.com \
--cc=emunson@mgebm.net \
--cc=glommer@redhat.com \
--cc=jeremy.fitzhardinge@citrix.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=riel@redhat.com \
/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