Re: [PATCH v4 1/2] semihosting/arm-compat: replace heuristic for softmmu SYS_HEAPINFO

2022-02-09 Thread Peter Maydell
On Wed, 9 Feb 2022 at 16:31, Alex Bennée wrote: > > > Peter Maydell writes: > > > On Wed, 23 Jun 2021 at 14:47, Alex Bennée wrote: > >> +static gint sort_secs(gconstpointer a, gconstpointer b) > >> +{ > >> +RomSec *ra = (RomSec *) a; > >> +RomSec *rb = (RomSec *) b; > > > > /* > > * Sor

Re: [PATCH v4 1/2] semihosting/arm-compat: replace heuristic for softmmu SYS_HEAPINFO

2022-02-09 Thread Alex Bennée
Peter Maydell writes: > On Wed, 23 Jun 2021 at 14:47, Alex Bennée wrote: >> >> The previous numbers were a guess at best and rather arbitrary without >> taking into account anything that might be loaded. Instead of using >> guesses based on the state of registers implement a new function that:

Re: [PATCH v4 1/2] semihosting/arm-compat: replace heuristic for softmmu SYS_HEAPINFO

2021-06-28 Thread Peter Maydell
On Wed, 23 Jun 2021 at 14:47, Alex Bennée wrote: > > The previous numbers were a guess at best and rather arbitrary without > taking into account anything that might be loaded. Instead of using > guesses based on the state of registers implement a new function that: > > a) scans the MemoryRegions

[PATCH v4 1/2] semihosting/arm-compat: replace heuristic for softmmu SYS_HEAPINFO

2021-06-23 Thread Alex Bennée
The previous numbers were a guess at best and rather arbitrary without taking into account anything that might be loaded. Instead of using guesses based on the state of registers implement a new function that: a) scans the MemoryRegions for the largest RAM block b) iterates through all "ROM" blo