[PATCH] D26177: [tsan] Add support for C++ exceptions into TSan (call __tsan_func_exit during unwinding)

Reid Kleckner via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 10 16:54:04 PST 2016


rnk added a comment.

In https://reviews.llvm.org/D26177#592464, @kubabrecka wrote:

> I tested the setjmp/longjmp and it's okay on Darwin and Linux.  Since this C++ exceptions support doesn't support exceptions on Windows, I didn't even try that.  Reid, could you test this patch for me if it breaks compilation on Windows?


I'm not set up to build tsan on Windows, it's only supported for gotsan. Dmitry knows how to build that, maybe he has time to test it.

> I'm also not sure what does it mean when a nounwind function calls something that's not nounwind.  Should we instrument in this case?

That's UB, so we don't need a cleanup, and we shouldn't insert one.

> Lastly, do you have an example that would trigger this instrumentation, but should not with -fno-exceptions?

I think the only way this can happen is if there's a bug in clang or a subsequent IR instrumentation pass that inserts new functions.


https://reviews.llvm.org/D26177





More information about the llvm-commits mailing list