mirror of
https://github.com/yuzu-emu/unicorn
synced 2024-11-24 22:48:22 +00:00
cpu: suffix cpu address spaces with cpu index
Renaming cpu address space names so that they won't be the same when there are more than one. Backports commit 87a621d857be1b2b3dd1d0847ca311a863dbcb53 from qemu
This commit is contained in:
parent
1bb34aadf9
commit
cd93d4eb52
1 changed files with 4 additions and 1 deletions
|
@ -538,9 +538,12 @@ void cpu_address_space_init(CPUState *cpu, int asidx,
|
||||||
{
|
{
|
||||||
CPUAddressSpace *newas;
|
CPUAddressSpace *newas;
|
||||||
AddressSpace *as = g_new0(AddressSpace, 1);
|
AddressSpace *as = g_new0(AddressSpace, 1);
|
||||||
|
char *as_name;
|
||||||
|
|
||||||
assert(mr);
|
assert(mr);
|
||||||
address_space_init(cpu->uc, as, mr, prefix);
|
as_name = g_strdup_printf("%s-%d", prefix, cpu->cpu_index);
|
||||||
|
address_space_init(cpu->uc, as, mr, as_name);
|
||||||
|
g_free(as_name);
|
||||||
|
|
||||||
/* Target code should have set num_ases before calling us */
|
/* Target code should have set num_ases before calling us */
|
||||||
assert(asidx < cpu->num_ases);
|
assert(asidx < cpu->num_ases);
|
||||||
|
|
Loading…
Reference in a new issue