From: Stefan Hajnoczi <stefanha@redhat.com>
To: qemu-devel@nongnu.org
Cc: "Michael S. Tsirkin" <mst@redhat.com>,
qemu-ppc@nongnu.org, "Paolo Bonzini" <pbonzini@redhat.com>,
"Fam Zheng" <fam@euphon.net>,
"Laurent Vivier" <laurent@vivier.eu>,
"Hanna Reitz" <hreitz@redhat.com>,
"Keith Busch" <kbusch@kernel.org>,
"Steven Lee" <steven_lee@aspeedtech.com>,
qemu-arm@nongnu.org, "Michael Tokarev" <mjt@tls.msk.ru>,
qemu-block@nongnu.org, "Peter Maydell" <peter.maydell@linaro.org>,
"Harsh Prateek Bora" <harshpb@linux.ibm.com>,
"Marc-André Lureau" <marcandre.lureau@redhat.com>,
"Frédéric Barrat" <fbarrat@linux.ibm.com>,
"Rob Herring" <robh@kernel.org>,
"Dmitry Fleytman" <dmitry.fleytman@gmail.com>,
"Jamin Lin" <jamin_lin@aspeedtech.com>,
qemu-s390x@nongnu.org, "Gerd Hoffmann" <kraxel@redhat.com>,
"Halil Pasic" <pasic@linux.ibm.com>,
"Kevin Wolf" <kwolf@redhat.com>,
"Jason Wang" <jasowang@redhat.com>,
"Cédric Le Goater" <clg@kaod.org>,
"Klaus Jensen" <its@irrelevant.dk>,
"Jeuk Kim" <jeuk20.kim@samsung.com>,
"Edgar E. Iglesias" <edgar.iglesias@gmail.com>,
"Daniel Henrique Barboza" <danielhb413@gmail.com>,
"Stefan Hajnoczi" <stefanha@redhat.com>,
"Nicholas Piggin" <npiggin@gmail.com>,
"Christian Borntraeger" <borntraeger@linux.ibm.com>,
"Andrew Jeffery" <andrew@codeconstruct.com.au>,
"Jesper Devantier" <foss@defmacro.it>,
qemu-trivial@nongnu.org, "Sven Schnelle" <svens@stackframe.org>,
"Philippe Mathieu-Daudé" <philmd@linaro.org>,
"Troy Lee" <leetroy@gmail.com>, "Joel Stanley" <joel@jms.id.au>,
"Thomas Huth" <thuth@redhat.com>,
"Hannes Reinecke" <hare@suse.com>,
"Alistair Francis" <alistair@alistair23.me>,
"Daniel P. Berrangé" <berrange@redhat.com>
Subject: [PULL v2 11/31] hw/audio/marvell_88w8618: skip automatic zero-init of large array
Date: Thu, 12 Jun 2025 13:48:55 -0400 [thread overview]
Message-ID: <20250612174855.238493-2-stefanha@redhat.com> (raw)
In-Reply-To: <20250612174855.238493-1-stefanha@redhat.com>
From: Daniel P. Berrangé <berrange@redhat.com>
The 'mv88w8618_audio_callback' method has a 4k byte array used for
copying data between the audio backend and device. Skip the automatic
zero-init of this array to eliminate the performance overhead in
the I/O hot path.
The 'buf' array will be fully initialized when reading data from
device memory.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Message-id: 20250610123709.835102-12-berrange@redhat.com
[Fixed hw/audio/gus in commit message --Stefan]
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
---
hw/audio/marvell_88w8618.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/audio/marvell_88w8618.c b/hw/audio/marvell_88w8618.c
index 6d3ebbb0c8..c5c79d083a 100644
--- a/hw/audio/marvell_88w8618.c
+++ b/hw/audio/marvell_88w8618.c
@@ -66,7 +66,7 @@ static void mv88w8618_audio_callback(void *opaque, int free_out, int free_in)
{
mv88w8618_audio_state *s = opaque;
int16_t *codec_buffer;
- int8_t buf[4096];
+ QEMU_UNINITIALIZED int8_t buf[4096];
int8_t *mem_buffer;
int pos, block_size;
--
2.49.0
next prev parent reply other threads:[~2025-06-12 17:49 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-12 17:48 [PULL v2 00/31] Block patches Stefan Hajnoczi
2025-06-12 17:48 ` Stefan Hajnoczi [this message]
2025-06-17 13:11 ` Stefan Hajnoczi
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=20250612174855.238493-2-stefanha@redhat.com \
--to=stefanha@redhat.com \
--cc=alistair@alistair23.me \
--cc=andrew@codeconstruct.com.au \
--cc=berrange@redhat.com \
--cc=borntraeger@linux.ibm.com \
--cc=clg@kaod.org \
--cc=danielhb413@gmail.com \
--cc=dmitry.fleytman@gmail.com \
--cc=edgar.iglesias@gmail.com \
--cc=fam@euphon.net \
--cc=fbarrat@linux.ibm.com \
--cc=foss@defmacro.it \
--cc=hare@suse.com \
--cc=harshpb@linux.ibm.com \
--cc=hreitz@redhat.com \
--cc=its@irrelevant.dk \
--cc=jamin_lin@aspeedtech.com \
--cc=jasowang@redhat.com \
--cc=jeuk20.kim@samsung.com \
--cc=joel@jms.id.au \
--cc=kbusch@kernel.org \
--cc=kraxel@redhat.com \
--cc=kwolf@redhat.com \
--cc=laurent@vivier.eu \
--cc=leetroy@gmail.com \
--cc=marcandre.lureau@redhat.com \
--cc=mjt@tls.msk.ru \
--cc=mst@redhat.com \
--cc=npiggin@gmail.com \
--cc=pasic@linux.ibm.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=philmd@linaro.org \
--cc=qemu-arm@nongnu.org \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
--cc=qemu-s390x@nongnu.org \
--cc=qemu-trivial@nongnu.org \
--cc=robh@kernel.org \
--cc=steven_lee@aspeedtech.com \
--cc=svens@stackframe.org \
--cc=thuth@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;
as well as URLs for NNTP newsgroup(s).