[cfe-dev] Porting libcxxabi / Unwind to Windows / MingW 32 bit

Yaron Keren yaron.keren at gmail.com
Sat Nov 2 04:02:55 PDT 2013


Hi Anton,

On Windows, MingW, libgcc arrives pre-compiled as shared (DLL) and a static
library. I'm not sure if the ld linker could help when starting from a
compiled binary DLL.
In any case, instead of hacking around libgcc, completely replacing it with
libcxxabi/Unwind + compiler-rt (thanks Jean!) seems to be the better
alternative.

Yaron




2013/11/2 Anton Korobeynikov <anton at korobeynikov.info>

> > Yes, it's nice when the OS does the work.
> >
> > With MingW, I see a problem using our unwind library.
> > __EH_FRAME_BEGIN__ is a local symbol with no external visibility
> > outside the libgcc DLL. There is no API exposing it either.
> > Only code compiled inside libgcc can access it.
> In fact, no. We can (with linker support, surely), put all the EH info
> into the dedicated section in the PE file. And do pretty similar
> things, but walking the sections of PE file.
>
> > The right solution would be to have a full replacement to libgcc based on
> > our
> > unwind code and use it instead. In addition to unwinding library, libgcc
> > also
> > supplies conversion and arithmetic functions so we'll need alternative
> > versions
> > of these too.
> http://compiler-rt.llvm.org/ ? :)
>
> --
> With best regards, Anton Korobeynikov
> Faculty of Mathematics and Mechanics, Saint Petersburg State University
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20131102/2fb3eed5/attachment.html>


More information about the cfe-dev mailing list