[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Translate signal to C++ exception
-----BEGIN PGP SIGNED MESSAGE-----
On 10.04.2016 09:07, Martin Husemann wrote:
> On Sat, Apr 09, 2016 at 11:06:56PM +0200, Kamil Rytarowski wrote:
>>> Are we talking about sync or async signals? For sync signals,
>>> it is no big issue. Async signals are a whole lot different and
>>> sigaltstack is difficult to avoid for them.
>> SIGSEGV from the code, I assume it's synchronous one from the
>> program point of view.
> What about FP exceptions?
> It probably would help if you post the complete list of exceptions
> generated and the siginfo details (there must be a mapping in the
> code), as from windows background I would expect it to be very
> limited and far away from the general case.
For now all exceptions to handle is bad memory address write or read.
I expect also division by 0 - but it will pop up in tests with running
the managed code.
Ithers like stack overflow are to be ignored.
> Couldn't we arrange for a special return trampoline that is
> registered upfront with a per thread exception object for each
> mapping, then fill it in the handler with usefull information and
> have the trampoline return it as the exception object? And have the
> application abort on recursive exceptions of the same type?
Is it doable with 7.0 (if not in 7.0.1/7.1?)? If so how? I was looking
at API to register new trampoline, it's available in the GNU world but
I missed this possibility in our case.
I also noted that our trampoline isn't recognized by GDB, I wasn't
investigating it deeply.. but shouldn't the code use CFI markers? I
will try to research it prepare a patch and see what happens.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
-----END PGP SIGNATURE-----
Main Index |
Thread Index |