[PATCH][X86_64/MC] Emit personality function and Dwarf EH data for Win64 SEH

Anton Korobeynikov anton at korobeynikov.info
Sun Sep 15 11:45:41 PDT 2013


Kai,

Just to make stuff clear: are you going to submit clang patches, so
the _GCC_specific_handler is emitted in IR on mingw64, for example?

On Sun, Sep 15, 2013 at 10:27 PM, Kai Nacke <kai.nacke at redstar.de> wrote:
> Hi!
>
> Currently, the MC code emits a hard-coded name for the personality function.
> Obviously the function specified by the user should be emitted as language
> handler.
> There is no special language data section for SEH. Instead the data is
> emitted after the unwind data and the reference to the handler function.
> See also the specification for the struct UNWIND_INFO in the msdn:
> http://msdn.microsoft.com/en-us/library/ddssxxy8.aspx
>
> This is the same as gcc 4.8.0 does. In case of SEH the handler function is
> called __gcc_personality_imp and the LSDA is stored in the handler data.
>
> The attached patch changes the output to be conformant to the specification.
> As of now there is no code path which can trigger this code therefore no
> test case is included. My next patch enables proper EH handling on Win64 and
> will include test cases for this change, too.
>
> Please review.
>
> Regards
> Kai



-- 
With best regards, Anton Korobeynikov
Faculty of Mathematics and Mechanics, Saint Petersburg State University



More information about the llvm-commits mailing list