Mingw-w64 exception handling configuration

Sandra Loosemore sandra@codesourcery.com
Sat May 14 02:22:00 GMT 2016


On 05/12/2016 09:27 AM, Sandra Loosemore wrote:
> I see that the default EH behavior for a biarch mingw-w64 target GCC is
> to use SJLJ for the 32-bit multilib and SEH for the 64-bit one, but that
> there are #errors in cygming.h and mingw32.h that prevent you from
> configuring a biarch build with --disable-sjlj-exceptions to use DWARF-2
> and SEH, respectively.  Is there a deep reason for this, or is this just
> a case where nobody updated the configuration logic after SEH was
> implemented?  I understand that before that, you had to use SJLJ for
> 64-bit targets because the DWARF-2 support is restricted to 32-bit
> targets, so it was completely reasonable to error out.

Following up my own post....

I did some experimentation, and it looks like this is indeed just a 
result of bit-rotten configuration logic.  I hacked up the attached 
patch against our local GCC 5.2 branch and built and tested it as a 
cross-compiler (C and C++ front ends only).  Test results for the 
--disable-sjlj-exceptions case have a few differences compared to 
--enable-sjlj-exceptions but they're not particularly better or worse.

Maintainers, any guidance on getting this into trunk?  E.g. I am not 
particularly interested in Cygwin target and have not tried to build 
that, but this affects code common to both Cygwin and Mingw-w64.

-Sandra

-------------- next part --------------
A non-text attachment was scrubbed...
Name: mingw.log
Type: text/x-log
Size: 436 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc/attachments/20160514/8315f47d/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mingw.patch
Type: text/x-patch
Size: 2867 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc/attachments/20160514/8315f47d/attachment-0001.bin>


More information about the Gcc mailing list