aheejin wrote: I see. Yeah, the current implementation only focuses on C++ support and we didn't really consider other languages or interops with C++ much when doing this.
I think giving each function a choice of personality function depending on the language is a good idea. We may be able to configure the exception tag (`__cpp_exception` for C++) based on the personality function. Given that `_Unwind_CallPersonality` is mostly a wrapper from our libunwind, making it a personality function within the bitcode signature seems a little awkward though. As I said the benefit of having it is we can save some instructions per catch site. Maybe we should rename it. Or getting rid of it entirely may not the end of world, because C++'s exception usage is dominated by destructors and the number of try-catches is usually small. Are you planning to submit patches for this? https://github.com/llvm/llvm-project/pull/175202 _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
