On 22.06.2018 16:32, Peter Maydell wrote: > On 22 June 2018 at 14:46, Philippe Mathieu-Daudé <f4...@amsat.org> wrote: >> hw_error() is only meant for CPU errors (since it dumps the CPU state). > > I would disagree. hw_error() dumps the state of every CPU. The > corresponding function for CPU errors is cpu_abort(), which > dumps only the state of the relevant CPU. It is used pretty > much only by device models, not by cpu models. > > In any case, this is one of those functions that's a left > over from a more innocent time when causing QEMU to bomb out > with a screenful of hexdump was a reasonable response to the > guest doing something weird or unsupported.
... but I really wonder why this function got so popular in the hw/ folder. Printing a dump of all CPU states does not make much sense in most of the cases (which are really not directly related to CPU states). So yes, we should try to slowly get rid of hw_error() these days! Thomas