qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v4 00/10] linux-user: Detect and report host crashes


From: Richard Henderson
Subject: Re: [PATCH v4 00/10] linux-user: Detect and report host crashes
Date: Tue, 19 Sep 2023 10:38:34 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.15.1

On 9/19/23 10:26, Michael Tokarev wrote:
19.09.2023 11:00, Helge Deller wrote:
..
Probably the right solution is to use qemu_abort() (and qemu_assert() etc),
and maybe #define abort(x) qemu_abort(x).  Even if some way to redefine
abort like the above will work on glibc, it does not mean it will work
on *bsd and in other contexts.

True. That's probably the better solution.

That wont work, since abort() gets called from a lot of libraries
(gilbc has 1000s of calls to it)

Sigh.

/mjt

A possible solution that occurs to me is to treat SIGABRT like patch 7 of this patch set treats SIGPROF: remap the guest signal to one of the host RT signals.

Then we leave the host SIGABRT as SIG_DFL, producing the expected crash when the signal originates from a host abort() (etc). A guest abort() would use a different signal which is caught and emulated.

Things do get confusing across processes, but should be no worse than any of the existing signal number swizzling.

Thoughts?


r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]