From: "Roger Pau Monné" <roger.pau@citrix.com>
To: Stewart Hildebrand <stewart.hildebrand@amd.com>
Cc: Jan Beulich <jbeulich@suse.com>,
"xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>
Subject: Re: [PATCH] vPCI: make vpci_add_register() an out-of-line function
Date: Tue, 23 Dec 2025 16:28:59 +0100 [thread overview]
Message-ID: <aUq1OwdjVdqkt5Ov@Mac.lan> (raw)
In-Reply-To: <4db98b05-5277-4ca4-a6bb-0054490a0280@amd.com>
On Thu, Dec 18, 2025 at 11:02:40AM -0500, Stewart Hildebrand wrote:
> On 12/18/25 05:45, Jan Beulich wrote:
> > Calling a function with 10 arguments is inefficient on many architectures:
> > x86-64 allows for up to 6 register parameters, Arm64 for up to 8.
> > Everything else needs passing on the stack, i.e. forcing the compiler to
> > emit stack manipulation insns at every call site.
> >
> > Shrinks generated code on x86 (with gcc15) by over 250 bytes. The gains on
> > Arm64 are a little less.
> >
> > Signed-off-by: Jan Beulich <jbeulich@suse.com>
>
> Reviewed-by: Stewart Hildebrand <stewart.hildebrand@amd.com>
Acked-by: Roger Pau Monné <roger.pau@citrix.com>
> > ---
> > Why is it, btw, that the declarations live in xen/vpci.h? These functions
> > aren't supposed to be called from outside xen/drivers/vpci/, are they? In
> > which case their decls may better live in a private header?
>
> You have a good point, they could very well live in a private header IMO.
In fact most of vpci.h could become private.
vpci_{,de}assign_device() must obviously be public, plus a couple more
to satisfy calls from external sites: vpci_{read,write}(),
vpci_dump_msi(), vpci_process_pending() and vpci_reset_device().
Maybe something else I'm missing, but not a lot more.
Thanks, Roger.
prev parent reply other threads:[~2025-12-23 15:29 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-18 10:45 [PATCH] vPCI: make vpci_add_register() an out-of-line function Jan Beulich
2025-12-18 16:02 ` Stewart Hildebrand
2025-12-23 15:28 ` Roger Pau Monné [this message]
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=aUq1OwdjVdqkt5Ov@Mac.lan \
--to=roger.pau@citrix.com \
--cc=jbeulich@suse.com \
--cc=stewart.hildebrand@amd.com \
--cc=xen-devel@lists.xenproject.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.