[cfe-dev] Trying out SjLj exception handling on Win32

Anton Korobeynikov anton at korobeynikov.info
Thu Nov 24 08:52:08 PST 2011


> I set (unconditionally, only for testing)
> ExceptionsType = ExceptionHandling::SjLj;
> in X86MCAsmInfoCOFF. This leads to an error message when compiling with clang++:
> fatal error: error in backend: Cannot select: intrinsic %llvm.eh.sjlj.lsda
>
> Which is telling me I missed something. I can't find the origin of the
> error, or where I should look to make it go away.
Instruction selector on x86 does not know how to expand the mentioned intrinsic.
If you really want sjlj exceptions on windows you should (at least):

1. Make sure the frontend emits the proper IR (e.g. compatible with gcc)
2. Implement the necessary lowering & instruction selection code

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



More information about the cfe-dev mailing list