From: Andre Przywara <andre.przywara@amd.com>
To: john cooper <john.cooper@redhat.com>
Cc: qemu-devel@nongnu.org, KVM list <kvm@vger.kernel.org>
Subject: [Qemu-devel] Re: [PATCH] Add cpu model configuration support.. (resend)
Date: Tue, 2 Feb 2010 12:07:09 +0100 [thread overview]
Message-ID: <4B68075D.2030701@amd.com> (raw)
In-Reply-To: <4B672535.5050303@redhat.com>
John,
just two comments from skimming through the patch:
> diff --git a/sysconfigs/target/target-x86_64.conf b/sysconfigs/target/target-x86_64.conf
> new file mode 100644
> index 0000000..43ad282
> --- /dev/null
> +++ b/sysconfigs/target/target-x86_64.conf
> @@ -0,0 +1,86 @@
> +# x86 CPU MODELS
> +
> +[cpudef]
> + name = "Conroe"
> + level = "2"
> + vendor = "GenuineIntel"
> + family = "6"
> + model = "2"
> + stepping = "3"
> + feature_edx = "sse2 sse fxsr mmx pat cmov pge sep apic cx8 mce pae msr tsc pse de fpu mtrr clflush mca pse36"
> + feature_ecx = "sse3 ssse3"
> + extfeature_edx = "fxsr mmx pat cmov pge apic cx8 mce pae msr tsc pse de fpu lm syscall nx"
> + extfeature_ecx = "lahf_lm"
Wouldn't it be much more user friendly to merge them all into one
string? Just from the feature names it is quite obscure to guess which
flag belongs into which string (especially since we lack the EXTn_
prefix we had in helper.c). I haven't tried it, but the parsing code
looks like this shouldn't be too hard.
To avoid overlong lines one could think about a += operator.
> @@ -129,7 +201,14 @@ typedef struct x86_def_t {
> CPUID_MSR | CPUID_MCE | CPUID_CX8 | CPUID_PGE | CPUID_CMOV | \
> CPUID_PAT | CPUID_FXSR | CPUID_MMX | CPUID_SSE | CPUID_SSE2 | \
> CPUID_PAE | CPUID_SEP | CPUID_APIC)
> -static x86_def_t x86_defs[] = {
> +
> +/* maintains list of cpu model definitions
> + */
> +static x86_def_t *x86_defs = {NULL};
> +
> +/* built-in cpu model definitions (deprecated)
> + */
> +static x86_def_t builtin_x86_defs[] = {
> #ifdef TARGET_X86_64
> {
> .name = "qemu64",
I would just drop all definitions here except qemu{32,64} and
kvm{32,64}. The other models should be described in the config file.
Regards,
Andre.
--
Andre Przywara
AMD-Operating System Research Center (OSRC), Dresden, Germany
Tel: +49 351 448 3567 12
----to satisfy European Law for business letters:
Advanced Micro Devices GmbH
Karl-Hammerschmidt-Str. 34, 85609 Dornach b. Muenchen
Geschaeftsfuehrer: Andrew Bowd; Thomas M. McCoy; Giuliano Meroni
Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen
Registergericht Muenchen, HRB Nr. 43632
next prev parent reply other threads:[~2010-02-02 11:07 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-01 19:02 [Qemu-devel] [PATCH] Add cpu model configuration support.. (resend) john cooper
2010-02-02 10:17 ` [Qemu-devel] " Andre Przywara
2010-02-02 11:07 ` Andre Przywara [this message]
2010-02-02 19:34 ` john cooper
2010-02-06 18:59 ` [Qemu-devel] [PATCH] Add assignment operation to config file parser john cooper
2010-02-07 16:24 ` Anthony Liguori
2010-02-08 13:21 ` Gerd Hoffmann
2010-02-08 16:00 ` john cooper
2010-06-09 8:05 ` [Qemu-devel] [PATCH] Add optional dump of default config file paths john cooper
2010-06-14 17:01 ` Anthony Liguori
2010-06-14 17:07 ` Daniel P. Berrange
2010-06-14 17:59 ` john cooper
2010-06-14 19:13 ` Anthony Liguori
2010-02-10 20:00 ` [Qemu-devel] [PATCH] Add cpu model configuration support.. (resend) Anthony Liguori
2010-02-14 6:52 ` john cooper
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=4B68075D.2030701@amd.com \
--to=andre.przywara@amd.com \
--cc=john.cooper@redhat.com \
--cc=kvm@vger.kernel.org \
--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).