Skip to content

Generate x86 cpu features

Tim Wiederhake qemu-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 5 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4target/i386: Split out feature_word_infotarget/i386/cpu.c target/i386/feature_word_info.c.inc+677 -6761 reply
2/4target/i386: Translate feature_word_info to xmltarget/i386/feature_word_info.xml+1607 -04 replies
3/4target/i386: Format feature_word_info.c.inctarget/i386/feature_word_info.c.inc+128 -1020 replies
4/4target/i386: Autogenerate feature_word_info.c.inctarget/i386/feature_word_info.c.inc target/i386/feature_word_info.py target/i386/feature_word_info.xml+115 -00 replies

Reviews trailers per patch

1 of 4 patches has a Reviewed-by or Acked-by.

PatchPhilippe Mathieu-Daudé
1/4R-b
2/4
3/4
4/4

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/4] Generate x86 cpu features

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
Signature · 1 line
2.39.2