[LLVMdev] catch all

Duncan Sands baldrick at free.fr
Tue May 12 05:43:02 PDT 2009

Hi zhangzw,

> I mean
> there are only the  catch(...) statement   can be translate to the LLVM-IR :
>  eh_select = tail call i32 (i8*, i8*, ...)* @llvm.eh.selector.i32(i8*
> %eh_ptr, i8* bitcast (i32 (...)*  @__gxx_personality_v0 to i8*), i8*
> null)
> are there any other case can be translate to the same above LLVM-IR ?

currently llvm-gcc uses a horrible hack and *always* puts null (catch all)
at the end of the selector (if it wasn't already there) IIRC.  This is needed
to get rethrowing of exceptions working properly when invokes are inlined
into other functions.  I have a plan to fix this, and while it's not complete
I expect to commit some initial code this week sometime.



More information about the llvm-dev mailing list