From: Paolo Bonzini <pbonzini@redhat.com>
To: Markus Armbruster <armbru@redhat.com>
Cc: qemu-devel@nongnu.org, Gerd Hoffmann <kraxel@redhat.com>,
"Michael S. Tsirkin" <mst@redhat.com>
Subject: [Qemu-devel] Re: [PATCH] add VMSTATE_BOOL
Date: Tue, 09 Nov 2010 10:32:46 +0100 [thread overview]
Message-ID: <4CD9153E.6060807@redhat.com> (raw)
In-Reply-To: <m3k4kmn955.fsf@blackfin.pond.sub.org>
On 11/09/2010 10:23 AM, Markus Armbruster wrote:
>>> +}
>>> +
>>> +static void put_bool(QEMUFile *f, void *pv, size_t size)
>>> +{
>>> + bool *v = pv;
>>> + qemu_put_byte(f, *v);
>>
>> Is there a guarantee that bool is a single byte, BTW?
>
> Nope. Does it matter?
No. In fact I think QEMU makes (or tries to make) the QEMU dump format
host-independent, and hence ABI-independent. So, writing a single byte
is better than writing sizeof(bool) bytes.
Paolo
next prev parent reply other threads:[~2010-11-09 9:35 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-01 14:51 [Qemu-devel] [PATCH] add VMSTATE_BOOL Gerd Hoffmann
2010-11-01 15:08 ` [Qemu-devel] " malc
2010-11-08 17:47 ` Michael S. Tsirkin
2010-11-09 9:23 ` Markus Armbruster
2010-11-09 9:32 ` Paolo Bonzini [this message]
2010-11-09 9:37 ` Gerd Hoffmann
2010-11-09 11:34 ` Michael S. Tsirkin
2010-11-09 11:50 ` Gerd Hoffmann
2010-11-09 13:05 ` Michael S. Tsirkin
2010-11-09 13:28 ` Gerd Hoffmann
2010-11-09 13:37 ` Michael S. Tsirkin
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=4CD9153E.6060807@redhat.com \
--to=pbonzini@redhat.com \
--cc=armbru@redhat.com \
--cc=kraxel@redhat.com \
--cc=mst@redhat.com \
--cc=qemu-devel@nongnu.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 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).