[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux
From: |
Lobron, David |
Subject: |
Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux |
Date: |
Mon, 11 Dec 2017 17:09:39 +0000 |
>>> Just use @try and @catch. If you can find a smallish test case, please
>>> file a bug on GitHub and I’ll take a look. Ideally, a test case shouldn’t
>>> depend on anything other than libobjc2 - take a look at the existing EH
>>> tests and see if you can make a similar one that shows the issue.
>>
>> I've been trying combinations of C++ and ObjC exceptions in a .mm file, and
>> so far I haven't been able to reproduce the abort behavior. I've attached
>> my latest code, which throws ObjC and C++ exceptions from C++ and ObjC
>> classes, and catches them. Please let me know if you can think of any
>> variations I haven't tried here.
>>
>
> If the failure is what I suspect that it is, then it’s a problem caused by
> mixing C++ and Objective-C exception unwinding, so it won’t be possible to
> reproduce in a single file. You will need to throw an exception from
> Objective-C++ and have it pass through stack frames from an Objective-C
> compilation unit that includes an @finally block that runs some code, and
> then be caught in an Objective-C++ compilation unit.
Ah, got it. I will try this.
Would separate .o files linked into a single binary be sufficient for counting
as separate compilation units? Or would it be better to compile and link a
shared library, and pick it up at runtime?
--David
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, (continued)
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, Lobron, David, 2017/12/06
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, David Chisnall, 2017/12/06
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, Lobron, David, 2017/12/06
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, David Chisnall, 2017/12/07
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, Lobron, David, 2017/12/07
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, David Chisnall, 2017/12/07
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, Lobron, David, 2017/12/07
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, David Chisnall, 2017/12/07
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, Lobron, David, 2017/12/11
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, David Chisnall, 2017/12/11
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux,
Lobron, David <=
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, David Chisnall, 2017/12/11
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, Lobron, David, 2017/12/11
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, David Chisnall, 2017/12/12
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, Lobron, David, 2017/12/12
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, David Chisnall, 2017/12/12
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, Lobron, David, 2017/12/18
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, David Chisnall, 2017/12/18
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, Lobron, David, 2017/12/18
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, David Chisnall, 2017/12/18
- Re: Mysterious crash in NSRunLoop, using libobjc2 on Linux, Lobron, David, 2017/12/19