CodeExtractor and InvokeInst

Hello LLVMDev,

I'm trying to extract a loop that contains invoke instructions into
separate function. But CodeExtractor thinks it is illegal to do it.
My guess is that it is semantically wrong to move the landingpad? My
question is that what people do in this kind of situation? Rewrite
the original code in C, or just give up? Thank you so much.