[PATCH 0/2] target/arm: Deprecate '-cpu any'
Arm '-cpu any' is aliased to '-cpu max' since more than 5 years. Deprecate the former in preparation of removal. Philippe Mathieu-Daudé (2): target/arm: Remove dead code target/arm: Deprecate '-cpu any' (remplaced by '-cpu max') docs/about/deprecated.rst | 8 ++++++++ target/arm/cpu.c | 1 + target/arm/tcg/cpu32.c | 3 --- 3 files changed, 9 insertions(+), 3 deletions(-) -- 2.52.0
Since commit a0032cc5427 ("target/arm: Make 'any' CPU just an alias for 'max'") the 'any' entry is never used (we use 'max' instead): remove it. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> --- target/arm/tcg/cpu32.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/target/arm/tcg/cpu32.c b/target/arm/tcg/cpu32.c index 0b0bc96bac2..2127d456ad6 100644 --- a/target/arm/tcg/cpu32.c +++ b/target/arm/tcg/cpu32.c @@ -897,9 +897,6 @@ static const ARMCPUInfo arm_tcg_cpus[] = { #ifndef TARGET_AARCH64 { .name = "max", .initfn = arm_max_initfn }, #endif -#ifdef CONFIG_USER_ONLY - { .name = "any", .initfn = arm_max_initfn }, -#endif }; static const TypeInfo idau_interface_type_info = { -- 2.52.0
Since more then 5 years the '-cpu any' is aliased to '-cpu max' (see commit a0032cc5427 "target/arm: Make 'any' CPU just an alias for 'max'"). Time to deprecate the alias so we can eventually remove the alias code. Emit a warnig meanwhile. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> --- docs/about/deprecated.rst | 8 ++++++++ target/arm/cpu.c | 1 + 2 files changed, 9 insertions(+) diff --git a/docs/about/deprecated.rst b/docs/about/deprecated.rst index 1d5c4f3707c..c544f23cab5 100644 --- a/docs/about/deprecated.rst +++ b/docs/about/deprecated.rst @@ -181,6 +181,14 @@ is going to be so much slower it wouldn't make sense for any serious instrumentation. Due to implementation differences there will also be anomalies in things like memory instrumentation. +User emulation CPUs +------------------- + +Arm 'any' CPU (since 11.0) +'''''''''''''''''''''''''' + +The Arm 'any' CPU is an alias for the 'max' CPU. Use the latter instead. + System emulator CPUs -------------------- diff --git a/target/arm/cpu.c b/target/arm/cpu.c index 6e1cbf3d614..2cf3273e8ab 100644 --- a/target/arm/cpu.c +++ b/target/arm/cpu.c @@ -2218,6 +2218,7 @@ static ObjectClass *arm_cpu_class_by_name(const char *cpu_model) * which has the same semantics as "-cpu max". */ if (!strcmp(cpunamestr, "any")) { + warn_report("CPU type 'any' is deprecated, use 'max' instead."); cpunamestr = "max"; } #endif -- 2.52.0
участники (1)
-
Philippe Mathieu-Daudé