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: [build] Move MD_UNWIND_SUPPORT to toplevel libgcc


2011/5/31 Paolo Bonzini <bonzini@gnu.org>:
> On 05/30/2011 07:54 PM, Kai Tietz wrote:
>>
>> > -/* For 64-bit Windows we can't use DW2 unwind info. Also for multilib
>> > - ? builds we can't use it, too. ?*/
>> > -#if !TARGET_64BIT_DEFAULT&& ?!defined (TARGET_BI_ARCH)
>> > -#define MD_UNWIND_SUPPORT "config/i386/w32-unwind.h"
>> > -#endif
>> > -
>> > ? /* This matches SHLIB_SONAME and SHLIB_SOVERSION in t-cygming. */
>> > ? /* This matches SHLIB_SONAME and SHLIB_SOVERSION in t-cygwin. */
>> > ? #if DWARF2_UNWIND_INFO
>>
>> mingw part is not ok, as it breaks 32-bit defaulted multilib version
>> compiler.
>
> Can you explain what is going on here? ?Could it be fixed by wrapping
> w32-unwind.h in a #ifdef __x86_64__?

To wrap it into __x86_64__ won't help. The issue is that in
combination of 32-bit and 64-bit we need to default here to SjLj, as
64-bit doesn't support dw2 unwinding stuff and uses here internally
instead SEH. So if target is 32-bit default, but a multilib version is
used, we can't use w32-unwind.h.

The line of interest is "#if !TARGET_64BIT_DEFAULT &&  !defined
(TARGET_BI_ARCH)", which says: if target is 64-bit then don't use
w32-unwind.h. if we are building for multilib then don't use
w32-unwind.h.

Well, wrapping header with __x64_64__ might helper partial. . But this
might be worth a try. Nevertheless I assume that then at least
produced DLL names for libgcc could get confused for their extensions.
Rainer: It would be helpful, if you could try this.

> Rainer, the same solution that is found for Windows should be used for
> darwin, too.
>
> Paolo


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