[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] qapi-schema.json: Reformat TargetType enum to o

From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH] qapi-schema.json: Reformat TargetType enum to one-per-line
Date: Mon, 20 May 2013 10:57:23 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130514 Thunderbird/17.0.6

On 05/20/2013 10:47 AM, Peter Maydell wrote:
> On 20 May 2013 17:41, Eric Blake <address@hidden> wrote:
>> Yep, that raises (once again) the question of dynamic introspection -
>> there's a difference between the maximum amount of information known at
>> compile time, and the subset of enum values that are actually usable at
>> runtime.  This list is static (all known architectures)
> It's not really static though for practical purposes. The user
> still has to be able to cope with "I know about architecture foo
> but it's not in the list" (if talking to an older qemu) or
> "the list contains architecture bar which I don't know about"
> (if talking to a newer qemu). I think the only thing we really
> need to avoid is changing the name of an existing architecture?

I'm not talking about keeping the enum static as in unchanging in all
future qemu releases, so much as static in that "at the time qemu was
compiled, this was the list of architectures qemu knew about".  But what
good does it do to know what other architectures the compile-time qemu
knew about, when what we really care about is what does THIS qemu binary
emulate.  And Paolo raised the point that what we really care about is
static-per-binary - that is, each binary supports exactly one
architecture (unless you are doing a LOT of work to support multi-arch
emulation from a single binary!).

Changing the name of an architecture would be reflected by having a
different qemu-FOO binary name, right?  If that's the case, then
introspection of which architectures are supported is done by listing
all the matches to qemu-* in the directory where binaries are installed,
and we don't need a QMP enum duplicating what the file system already
tells us.

Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]