From: Igor Mammedov <imammedo@redhat.com>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH for-2.11 v3 00/25] complete cpu QOMification and remove cpu_FOO_init() helpers
Date: Thu, 24 Aug 2017 18:31:23 +0200 [thread overview]
Message-ID: <1503592308-93913-1-git-send-email-imammedo@redhat.com> (raw)
ChangeLog since v2:
* rebase on top of rc4
* fix latent bug in cpu_generic_init()
[01/25] qom: cpu: fix parsed feature string length
* drop
[05/27] target-i386: cpu: convert plus/minus properties to global properties
[06/27] x86: extract legacy cpu features format parser
and replace
[07/27] sparc: replace custom cpu feature parsing with cpu_legacy_parse_featurestr()
with new patch
[06/25] sparc: make cpu feature parsing property
* pick up new Reviewed/Test-bys
ChangeLog since v1:
* rebase on top of rc3
* drop MIPS CPU QOMifying patches as it's superseeded
by another series: "[PATCH 0/8] QOMify MIPS cpu"
https://lists.gnu.org/archive/html/qemu-devel/2017-08/msg03041.html
* new patch to hide plus/minus features handling inside of feature parsing:
"target-i386: cpu: convert plus/minus properties to global properties"
* SPARC: make base CPU class abstract
While looking at ways to to get rid of ad-hoc cpu_model
parsing in every machine/*-user and unifying -cpu option
parsing, making it generic, I've noticed that most of
the targets have cpu_FOO_init() helper that does nothing
except of calling cpu_generic_init() and a few that do
additional ad-hoc cpu initialization outside of QOM model.
The most of the later could be easily fixed and
the 2 remaining mips/sparc targets are missing proper
conversion of cpu models to cpu subclasses and/or
cpu features to properties, with that fixed it's
possible get rid of custom cpu_FOO_init() helpers and
reuse cpu_generic_init() instead (which reduces code
size quite a bit).
That's what this series (1st part of cpu_model unification) does.
Patches:
* 2-7: complete QOMifying SPARC cpu including features into properties
conversion and cpu models into classes so it could use
cpu_generic_init() to create cpus.
above patches care only about completing CPU QOMinfication and
might be not pretty or clean as they could be,
but leave cleanups and follow up code simplification is way out of scope
and (might|should) be done on top by respective maintainers or someone
who cares about it.
* the rest of the patches are just replacing custom cpu_FOO_init()
with cpu_generic_init() and sometimes dealing with target
specific oddities in handling cpu name to typename conversion
git tree for testing/viewing:
https://github.com/imammedo/qemu.git cpu_init_def_target_cpu_V3
https://github.com/imammedo/qemu/commits/cpu_init_def_target_cpu_V3
Ref to v2:
https://www.mail-archive.com/qemu-devel@nongnu.org/msg474320.html
PS:
SPARC are the only targets that received 'heavy' refactoring
so I've treated them with more manual testing the rest of series if
slightly tested /make check for softmmu targets and running busybox for
the most of *-linux targets /, and not regressions were noticed.
And now about follow up series, as end result of unificathion,
I'm looking for:
- replacing many ad-hoc ways of specifying default cpu with
a one generic way
- cpu_model parsing done with common cpu_model_helper that
will be called from 3 places: generic machine code and [linux|bsd]-user
- cpu_model_helper returning cpu type name that
the rest of the code will deal with
- get rid of cpu_init() and leave only cpu_generic_init() throughout the tree
- make cpu_model_helper usable at pre machine_init() time
so that commands like hotplugable-cpus could be used
in with HMP/QMP preconfiguration interface I'm working on.
(it's the real reason why I'm doing all of of this)
Igor Mammedov (25):
qom: cpu: fix parsed feature string length
sparc: convert cpu models to SPARC cpu subclasses
sparc: embed sparc_def_t into CPUSPARCState
sparc: convert cpu features to qdev properties
sparc: move adhoc CPUSPARCState initialization to realize time
sparc: make cpu feature parsing property based
sparc: replace cpu_sparc_init() with cpu_generic_init()
s390x: replace cpu_s390x_init() with cpu_generic_init()
alpha: replace cpu_alpha_init() with cpu_generic_init()
hppa: replace cpu_hppa_init() with cpu_generic_init()
m68k: replace cpu_m68k_init() with cpu_generic_init()
microblaze: replace cpu_mb_init() with cpu_generic_init()
nios2: replace cpu_nios2_init() with cpu_generic_init()
tilegx: replace cpu_tilegx_init() with cpu_generic_init()
xtensa: replace cpu_xtensa_init() with cpu_generic_init()
tricore: replace cpu_tricore_init() with cpu_generic_init()
sh4: replace cpu_sh4_init() with cpu_generic_init()
arm: replace cpu_arm_init() with cpu_generic_init()
cris: replace cpu_cris_init() with cpu_generic_init()
x86: replace cpu_x86_init() with cpu_generic_init()
lm32: replace cpu_lm32_init() with cpu_generic_init()
moxie: replace cpu_moxie_init() with cpu_generic_init()
openrisc: replace cpu_openrisc_init() with cpu_generic_init()
unicore32: replace uc32_cpu_init() with cpu_generic_init()
ppc: replace cpu_ppc_init() with cpu_generic_init()
linux-user/sparc/target_syscall.h | 2 +-
target/alpha/cpu.h | 4 +-
target/arm/cpu.h | 3 +-
target/cris/cpu.h | 3 +-
target/hppa/cpu.h | 4 +-
target/i386/cpu.h | 3 +-
target/lm32/cpu.h | 3 +-
target/m68k/cpu.h | 3 +-
target/microblaze/cpu.h | 3 +-
target/moxie/cpu.h | 3 +-
target/nios2/cpu.h | 3 +-
target/openrisc/cpu.h | 4 +-
target/ppc/cpu.h | 3 +-
target/s390x/cpu.h | 3 +-
target/sh4/cpu.h | 3 +-
target/sparc/cpu-qom.h | 2 +
target/sparc/cpu.h | 11 +-
target/tilegx/cpu.h | 4 +-
target/tricore/cpu.h | 4 +-
target/unicore32/cpu.h | 4 +-
target/xtensa/cpu.h | 4 +-
hw/alpha/dp264.c | 8 +-
hw/arm/musicpal.c | 2 +-
hw/arm/omap1.c | 2 +-
hw/arm/omap2.c | 2 +-
hw/arm/pxa2xx.c | 4 +-
hw/arm/strongarm.c | 2 +-
hw/cris/axis_dev88.c | 2 +-
hw/lm32/lm32_boards.c | 4 +-
hw/lm32/milkymist.c | 2 +-
hw/m68k/an5206.c | 2 +-
hw/m68k/mcf5208.c | 2 +-
hw/moxie/moxiesim.c | 2 +-
hw/nios2/10m50_devboard.c | 2 +-
hw/openrisc/openrisc_sim.c | 2 +-
hw/ppc/e500.c | 3 +-
hw/ppc/mac_newworld.c | 3 +-
hw/ppc/mac_oldworld.c | 3 +-
hw/ppc/ppc440_bamboo.c | 2 +-
hw/ppc/ppc4xx_devs.c | 2 +-
hw/ppc/prep.c | 5 +-
hw/ppc/virtex_ml507.c | 2 +-
hw/sh4/r2d.c | 2 +-
hw/sh4/shix.c | 2 +-
hw/sparc/leon3.c | 2 +-
hw/sparc/sun4m.c | 2 +-
hw/sparc64/sparc64.c | 2 +-
hw/tricore/tricore_testboard.c | 2 +-
hw/unicore32/puv3.c | 2 +-
hw/xtensa/sim.c | 2 +-
hw/xtensa/xtfpga.c | 2 +-
qom/cpu.c | 14 +-
target/alpha/cpu.c | 20 +-
target/arm/helper.c | 5 -
target/cris/cpu.c | 5 -
target/hppa/cpu.c | 11 +-
target/i386/cpu.c | 5 -
target/lm32/helper.c | 5 -
target/m68k/cpu.c | 2 +
target/m68k/helper.c | 20 --
target/microblaze/cpu.c | 6 +
target/microblaze/translate.c | 11 --
target/moxie/cpu.c | 5 -
target/nios2/cpu.c | 9 +-
target/openrisc/cpu.c | 5 -
target/ppc/translate_init.c | 5 -
target/s390x/cpu.c | 7 +
target/s390x/helper.c | 14 --
target/sh4/cpu.c | 5 -
target/sparc/cpu.c | 384 +++++++++++++++++++++-----------------
target/sparc/int32_helper.c | 2 +-
target/sparc/int64_helper.c | 2 +-
target/sparc/ldst_helper.c | 14 +-
target/sparc/mmu_helper.c | 2 +-
target/sparc/translate.c | 2 +-
target/sparc/win_helper.c | 4 +-
target/tilegx/cpu.c | 11 +-
target/tricore/helper.c | 5 -
target/unicore32/helper.c | 5 -
target/xtensa/cpu.c | 3 +
target/xtensa/helper.c | 22 ---
81 files changed, 330 insertions(+), 432 deletions(-)
--
2.7.4
next reply other threads:[~2017-08-24 16:31 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-24 16:31 Igor Mammedov [this message]
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 01/25] qom: cpu: fix parsed feature string length Igor Mammedov
2017-08-24 17:00 ` Philippe Mathieu-Daudé
2017-08-25 8:11 ` Igor Mammedov
2017-08-25 11:55 ` Philippe Mathieu-Daudé
2017-08-25 13:16 ` Eduardo Habkost
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 02/25] sparc: convert cpu models to SPARC cpu subclasses Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 03/25] sparc: embed sparc_def_t into CPUSPARCState Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 04/25] sparc: convert cpu features to qdev properties Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 05/25] sparc: move adhoc CPUSPARCState initialization to realize time Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 06/25] sparc: make cpu feature parsing property based Igor Mammedov
2017-08-24 16:52 ` Philippe Mathieu-Daudé
2017-08-25 13:11 ` Eduardo Habkost
2017-08-25 14:47 ` [Qemu-devel] [PATCH for-2.11 v4 " Igor Mammedov
2017-08-25 17:56 ` Eduardo Habkost
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 07/25] sparc: replace cpu_sparc_init() with cpu_generic_init() Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 08/25] s390x: replace cpu_s390x_init() " Igor Mammedov
2017-08-31 13:19 ` [Qemu-devel] [PATCH for-2.11 v4 " Igor Mammedov
2017-08-31 13:44 ` David Hildenbrand
2017-08-31 14:04 ` Igor Mammedov
2017-08-31 16:20 ` David Hildenbrand
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 09/25] alpha: replace cpu_alpha_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 10/25] hppa: replace cpu_hppa_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 11/25] m68k: replace cpu_m68k_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 12/25] microblaze: replace cpu_mb_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 13/25] nios2: replace cpu_nios2_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 14/25] tilegx: replace cpu_tilegx_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 15/25] xtensa: replace cpu_xtensa_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 16/25] tricore: replace cpu_tricore_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 17/25] sh4: replace cpu_sh4_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 18/25] arm: replace cpu_arm_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 19/25] cris: replace cpu_cris_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 20/25] x86: replace cpu_x86_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 21/25] lm32: replace cpu_lm32_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 22/25] moxie: replace cpu_moxie_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 23/25] openrisc: replace cpu_openrisc_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 24/25] unicore32: replace uc32_cpu_init() " Igor Mammedov
2017-08-24 16:31 ` [Qemu-devel] [PATCH for-2.11 v3 25/25] ppc: replace cpu_ppc_init() " Igor Mammedov
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=1503592308-93913-1-git-send-email-imammedo@redhat.com \
--to=imammedo@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).