[compiler-rt] [rtsan][compiler-rt] Get rid of [[blocking]] stub in tests (PR #111392)
Chris Apple via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 7 09:49:44 PDT 2024
================
@@ -7,18 +7,11 @@
#include <stdio.h>
#include <stdlib.h>
-// TODO: Remove when [[blocking]] is implemented.
-extern "C" void __rtsan_notify_blocking_call(const char *function_name);
-
-void custom_blocking_function() {
- // TODO: When [[blocking]] is implemented, don't call this directly.
- __rtsan_notify_blocking_call(__func__);
+void custom_blocking_function() [[clang::blocking]] {
+ printf("In blocking function\n");
}
-void safe_call() {
- // TODO: When [[blocking]] is implemented, don't call this directly.
- __rtsan_notify_blocking_call(__func__);
-}
+void safe_call() [[clang::blocking]] { printf("In safe call\n"); }
----------------
cjappl wrote:
I just took a second crack at it with different assertions etc, let me know what you think
https://github.com/llvm/llvm-project/pull/111392
More information about the llvm-commits
mailing list