Turning a SIGSEGV into a regular function call under Linux, allowing throw

Vladimir Panteleev vladimir at thecybershadow.net
Wed Mar 14 10:28:59 PDT 2012


On Wednesday, 14 March 2012 at 17:18:06 UTC, deadalnix wrote:
> Le 14/03/2012 18:00, Vladimir Panteleev a écrit :
>> On Wednesday, 14 March 2012 at 16:37:45 UTC, deadalnix wrote:
>>> Le 14/03/2012 17:08, Vladimir Panteleev a écrit :
>>>> On Wednesday, 14 March 2012 at 11:11:54 UTC, deadalnix wrote:
>>>>> You are loosing EAX in the process.
>>>>
>>>> When would this matter? EAX is a scratch register per ABIs, 
>>>> no?
>>>
>>> You may want to return from the function the standard way an 
>>> resume
>>> operations. To implement a moving GC using page protection 
>>> for example.
>>
>> This doesn't have anything to do with turning signals into 
>> exceptions.
>
> No but this does, make sense to catch segfault and act 
> according to it to implement such a functionality. This is a 
> very close problem.

You can't resume D exceptions.


More information about the Digitalmars-d mailing list