This is the mail archive of the gcc-patches@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: PATCH: PR other/48007: Unwind library doesn't work with UNITS_PER_WORD > sizeof (void *)


"H.J. Lu" <hjl.tools@gmail.com> writes:

> On Tue, Mar 22, 2011 at 9:52 PM, Ian Lance Taylor <iant@google.com> wrote:
>> "H.J. Lu" <hjl.tools@gmail.com> writes:
>>
>>>> This suggests that, at least, when sizeof(_Unwind_Word) > sizeof(void*),
>>>> we need to extend _Unwind_Context with a new array at the end, and use
>>>> that new array when by_value[REG] is true.
>>>
>>> Will there be a case where 2 copies of unwind-dw2.c are within the same
>>> process?
>>
>> Sure, that's easy. ÂI think what you are really asking is: will there be
>> a case where we could call functions from one copy and then pass the
>> context to the functions from a different copy. ÂI don't know the answer
>> to that, but it doesn't seem impossible.
>>
>
> Then. will this be acceptable?

It's an interesting idea, but following this approach I think we clearly
want UNWIND_REGISTER_AS_UNION to be defined for any target for which
sizeof (_Unwind_Word) > sizeof (void *).  There is no reason to design a
system which will break for any such target.

Also, N32 is apparently broken right now if anybody adds some
hand-written CFI of the right sort, and this approach does not fix it.

Does anybody know of any existing target for which sizeof (_Unwind_Word)
> sizeof (void *) other than MIPS N32?

Do the MIPS maintainers have any opinion on whether we can theoretically
break the N32 exception handling ABI?  The only potential problem I've
been able to construct is a shared library linked against libgcc_eh.a
with -Bsymbolic which tries to unwind an exception through the
executable.  This is an unlikely scenario as we normally tell everybody
to link against libgcc_s.so.

Ian


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