qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 7/9] pc: acpi: drop not needed intermediate bitm


From: Eduardo Habkost
Subject: Re: [Qemu-devel] [PATCH 7/9] pc: acpi: drop not needed intermediate bitmap cpu->found_cpus
Date: Fri, 5 Feb 2016 13:39:07 -0200
User-agent: Mutt/1.5.23 (2014-03-12)

On Thu, Feb 04, 2016 at 12:47:33PM +0100, Igor Mammedov wrote:
> cpu->found_cpus bitmap is used for setting present
> flag in CPON AML package at start up. But it takes
> a bunch of code to fill bitmap and cloud be simplified
> by calling qemu_get_cpu_by_arch_id(apic_id) directly.
> 
> Hence do so and remove not used anymore bitmap
> with related utilities, which saves us ~32LOC
> and also would simplify consolidating APCI parts
> of CPU hotplug.
> 
> Signed-off-by: Igor Mammedov <address@hidden>

This makes the code loops through all smp_cpus CPUs max_cpus
times, instead of just looping through the smp_cpus CPUs once.

I'm all for making the code simpler, and there's an upper bound:
looking at CPU objects 64k times (because MAX_CPUMASK_BITS is
255). But I want to make sure we agree this is an optimization we
want to drop.

-- 
Eduardo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]