qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4] Generate x86 cpu features
@ 2023-08-11 13:50 Tim Wiederhake
  2023-08-11 13:50 ` [PATCH 1/4] target/i386: Split out feature_word_info Tim Wiederhake
                   ` (3 more replies)
  0 siblings, 4 replies; 10+ messages in thread
From: Tim Wiederhake @ 2023-08-11 13:50 UTC (permalink / raw)
  To: qemu-devel; +Cc: Tim Wiederhake

Synchronizing the list of cpu features and models with qemu is a recurring
task in libvirt. For x86, this is done by reading qom-list-properties for
max-x86_64-cpu and manually filtering out everthing that does not look like
a feature name, as well as parsing target/i386/cpu.c for cpu models.

This is a flawed, tedious and error-prone procedure. Ideally, qemu
and libvirt would query a common source for cpu feature and model
related information. Meanwhile, converting this information into an easier
to parse format would help libvirt a lot.

This patch series converts the cpu feature information present in
target/i386/cpu.c (`feature_word_info`) into an xml file and adds a
script to generate the c code from this xml.

A patch set to convert the cpu model data (`builtin_x86_defs`) in the
same way will follow.

Tim Wiederhake (4):
  target/i386: Split out feature_word_info
  target/i386: Translate feature_word_info to xml
  target/i386: Format feature_word_info.c.inc
  target/i386: Autogenerate feature_word_info.c.inc

 target/i386/cpu.c                   |  677 +----------
 target/i386/feature_word_info.c.inc |  704 ++++++++++++
 target/i386/feature_word_info.py    |  110 ++
 target/i386/feature_word_info.xml   | 1610 +++++++++++++++++++++++++++
 4 files changed, 2425 insertions(+), 676 deletions(-)
 create mode 100644 target/i386/feature_word_info.c.inc
 create mode 100755 target/i386/feature_word_info.py
 create mode 100644 target/i386/feature_word_info.xml

-- 
2.39.2



^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2023-09-06 14:35 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-11 13:50 [PATCH 0/4] Generate x86 cpu features Tim Wiederhake
2023-08-11 13:50 ` [PATCH 1/4] target/i386: Split out feature_word_info Tim Wiederhake
2023-09-06 14:34   ` Philippe Mathieu-Daudé
2023-08-11 13:50 ` [PATCH 2/4] target/i386: Translate feature_word_info to xml Tim Wiederhake
2023-08-17 11:07   ` Daniel P. Berrangé
2023-08-21  9:54     ` Tim Wiederhake
2023-09-06 14:33       ` Philippe Mathieu-Daudé
2023-09-06 14:21   ` Michael S. Tsirkin
2023-08-11 13:50 ` [PATCH 3/4] target/i386: Format feature_word_info.c.inc Tim Wiederhake
2023-08-11 13:50 ` [PATCH 4/4] target/i386: Autogenerate feature_word_info.c.inc Tim Wiederhake

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).