On 18/05/2020 19.08, Philippe Mathieu-Daudé wrote: > On 5/18/20 6:32 PM, Thomas Huth wrote: >> On 18/05/2020 11.49, Philippe Mathieu-Daudé wrote: >>> hw_error() calls exit(). This a bit overkill when we can log >>> the accesses as unimplemented or guest error. >> >> Good idea. hw_error() is also mainly for CPU errors, it really should >> not be used for non-CPU devices. > > Are you sure? > > $ git grep hw_error target | wc -l > 5 > $ git grep hw_error hw | wc -l > 137
Well, the function is defined in cpus.c and it's dumping the state of each CPU ... I think it's used in a lot of places during development of new code to quickly get some information on where things went wrong in the guest, but technically, it really sounds wrong to me that a non-CPU device creates CPU dumps in mature code. Thomas