pc: Parse CPU features only once
commit6aff24c6a61c6fec31e555c7748ba6085b7b2c06
authorIgor Mammedov <imammedo@redhat.com>
Thu, 9 Jun 2016 17:11:03 +0000 (9 19:11 +0200)
committerEduardo Habkost <ehabkost@redhat.com>
Thu, 7 Jul 2016 18:25:06 +0000 (7 15:25 -0300)
tree9fa1ae089159deb7effd2af104fcef3d17af29a3
parent09f71b054a95161950a03fafc9023637929bd404
pc: Parse CPU features only once

Considering that features are converted to global properties and
global properties are automatically applied to every new instance
of created CPU (at object_new() time), there is no point in
parsing cpu_model string every time a CPU created. So move
parsing outside CPU creation loop and do it only once.

Parsing also should be done before any CPU is created so that
features would affect the first CPU a well.

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
hw/i386/pc.c
qom/cpu.c
target-i386/cpu.c
target-i386/cpu.h