This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Divide_1 testsuite fail due to a problem in the unwinding code


> To my understanding this can only happen if there is control flow from
> a leaf function which in turn should only occur with signals.  Perhaps
> we could modify the CFA "a bit" for the frame where the signal
> occurred?  There is already a hack in uw_identify_context which does
> this for the signal frame:
>
> static inline _Unwind_Ptr
> uw_identify_context (struct _Unwind_Context *context)
> {
>   /* The CFA is not sufficient to disambiguate the context of a function
>      interrupted by a signal before establishing its frame and the context
>      of the signal itself.  */
>   if (STACK_GROWS_DOWNWARD)
>     return _Unwind_GetCFA (context) - _Unwind_IsSignalFrame (context);
>   else
>     return _Unwind_GetCFA (context) + _Unwind_IsSignalFrame (context);
> }

Why does this "hack" not work?  It was precisely devised for this purpose.

-- 
Eric Botcazou


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]