File tree Expand file tree Collapse file tree 1 file changed +1
-24
lines changed Expand file tree Collapse file tree 1 file changed +1
-24
lines changed Original file line number Diff line number Diff line change @@ -62,27 +62,8 @@ typedef unsigned long long uint64_t;
62
62
#include "InstrProfiling.h"
63
63
#include "InstrProfilingUtil.h"
64
64
65
- #ifndef _WIN32
66
- #include <pthread.h>
67
- static pthread_mutex_t gcov_flush_mutex = PTHREAD_MUTEX_INITIALIZER ;
68
- static __inline void gcov_flush_lock () {
69
- pthread_mutex_lock (& gcov_flush_mutex );
70
- }
71
- static __inline void gcov_flush_unlock () {
72
- pthread_mutex_unlock (& gcov_flush_mutex );
73
- }
74
- #else
75
- #include <windows.h>
76
- static SRWLOCK gcov_flush_mutex = SRWLOCK_INIT ;
77
- static __inline void gcov_flush_lock () {
78
- AcquireSRWLockExclusive (& gcov_flush_mutex );
79
- }
80
- static __inline void gcov_flush_unlock () {
81
- ReleaseSRWLockExclusive (& gcov_flush_mutex );
82
- }
83
- #endif
84
-
85
65
/* #define DEBUG_GCDAPROFILING */
66
+
86
67
/*
87
68
* --- GCOV file format I/O primitives ---
88
69
*/
@@ -639,16 +620,12 @@ void llvm_register_flush_function(fn_ptr fn) {
639
620
}
640
621
641
622
void __gcov_flush () {
642
- gcov_flush_lock ();
643
-
644
623
struct fn_node * curr = flush_fn_list .head ;
645
624
646
625
while (curr ) {
647
626
curr -> fn ();
648
627
curr = curr -> next ;
649
628
}
650
-
651
- gcov_flush_unlock ();
652
629
}
653
630
654
631
COMPILER_RT_VISIBILITY
You can’t perform that action at this time.
0 commit comments