From: "Michael S. Tsirkin" <mst@redhat.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: Isaku Yamahata <yamahata@valinux.co.jp>, qemu-devel@nongnu.org
Subject: [Qemu-devel] Re: [PATCH] qemu/pci: optimize pci config handling
Date: Wed, 7 Oct 2009 21:21:27 +0200 [thread overview]
Message-ID: <20091007192127.GA3796@redhat.com> (raw)
In-Reply-To: <4ACCA4AD.7050606@redhat.com>
On Wed, Oct 07, 2009 at 04:24:45PM +0200, Paolo Bonzini wrote:
>> I'm actively trying to get out of range-checking address.
>
> I don't understand what you mean, sorry.
>
>> What you porpose here is certainly more code than we had.
>> So why is this a good idea?
>
> Because it avoids the memcpy/memcmp most of the time (when the memcmp
> would surely succeed).
Yes :) But at the cost of more code. I don't think speed
matters there, so less code is good. But even if it did, extra
read of a single cache line might be cheaper than an extra branch,
and generated code will be more compact.
> I supposed that would also matter more as the
> config space size increases---correct me and dismiss the patch if I am
> mistaken.
No, we'll always only look need to look at the header, whatever the size
of the config space. That's the point of the patch I posted - future
proof against config space size increases, not optimization.
> Paolo
next prev parent reply other threads:[~2009-10-07 19:23 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-07 12:33 [Qemu-devel] [PATCH] qemu/pci: optimize pci config handling Michael S. Tsirkin
2009-10-07 13:01 ` [Qemu-devel] " Paolo Bonzini
2009-10-07 13:48 ` Michael S. Tsirkin
2009-10-07 14:24 ` Paolo Bonzini
2009-10-07 19:21 ` Michael S. Tsirkin [this message]
2009-10-08 8:23 ` Paolo Bonzini
2009-10-08 8:57 ` Michael S. Tsirkin
2009-10-08 0:08 ` Isaku Yamahata
2009-10-08 8:54 ` Michael S. Tsirkin
2009-10-08 9:29 ` Michael S. Tsirkin
2009-10-13 12:17 ` Isaku Yamahata
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=20091007192127.GA3796@redhat.com \
--to=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=yamahata@valinux.co.jp \
/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;
as well as URLs for NNTP newsgroup(s).