qemu-arm
[Top][All Lists]
Advanced

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

Re: [PATCH v2 4/8] linux-user/arm: Report SIGBUS and SIGSEGV correctly


From: Richard Henderson
Subject: Re: [PATCH v2 4/8] linux-user/arm: Report SIGBUS and SIGSEGV correctly
Date: Wed, 8 Sep 2021 11:19:13 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0

On 8/26/21 3:31 PM, Peter Maydell wrote:
Side note: for cases like this where we can tell MAPERR from
ACCERR based on info the exception handler passes to us, should
we prefer that or the "check the page flags" approach that
force_sigsegv_for_addr() takes ?  I feel like the former is
nicer, because in a multithreaded program some other thread
might have changed whether the page is mapped between our taking
the fault and getting here. But maybe that's always racy...

Both ways are racy.

After having played with SIGBUS, what I believe should happen is that we clean up the signal handling such that we can pass through the host MAPERR/ACCERR, remapping any fault address, after filtering the write-protect case that we care about.

I'm not sure how much effort it would be to do that. Certainly the test matrix is pretty darn large. But perhaps it would simplify the huge SIGBUS patch set, and thus make it all worthwhile.


r~



reply via email to

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