PR sanitizer/55702
* tsan.c (instrument_func_exit): Allow BUILT_IN_RETURN
functions.
* gcc.dg/pr55702.c: New test.
From-SVN: r197430
+2013-04-03 Marek Polacek <polacek@redhat.com>
+
+ PR sanitizer/55702
+ * tsan.c (instrument_func_exit): Allow BUILT_IN_RETURN
+ functions.
+
2013-04-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
PR target/56809
+2013-04-03 Marek Polacek <polacek@redhat.com>
+
+ PR sanitizer/55702
+ * gcc.dg/pr55702.c: New test.
+
2013-04-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
PR target/56809
--- /dev/null
+/* PR sanitizer/55702 */
+/* { dg-do compile { target { x86_64-*-linux* && lp64 } } } */
+/* { dg-options "-fsanitize=thread" } */
+
+void
+foo ()
+{
+ __builtin_return (0);
+}
{
gsi = gsi_last_bb (e->src);
stmt = gsi_stmt (gsi);
- gcc_assert (gimple_code (stmt) == GIMPLE_RETURN);
+ gcc_assert (gimple_code (stmt) == GIMPLE_RETURN
+ || gimple_call_builtin_p (stmt, BUILT_IN_RETURN));
loc = gimple_location (stmt);
builtin_decl = builtin_decl_implicit (BUILT_IN_TSAN_FUNC_EXIT);
g = gimple_build_call (builtin_decl, 0);