Skip to content

Commit e6e2058

Browse files
committed
update build test
1 parent a648405 commit e6e2058

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

example.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -104,17 +104,15 @@ void* worker_sc(void *arg)
104104

105105
#define join_threads \
106106
for (i = 0; i < nthreads; i++)\
107-
pthread_join(threads[i], NULL);\
108-
printf("current size= %d\n", (int) lfqueue_size(myq) )
107+
pthread_join(threads[i], NULL)
109108

110109
#define detach_thread_and_loop \
111110
for (i = 0; i < nthreads; i++)\
112111
pthread_detach(threads[i]);\
113112
while ( nthreads_exited < nthreads ) \
114113
lfqueue_sleep(10);\
115114
if(lfqueue_size(myq) != 0){\
116-
lfqueue_sleep(10);\
117-
printf("current size= %zu\n", lfqueue_size(myq) );\
115+
lfqueue_sleep(10);
118116
}
119117

120118
void multi_enq_deq(pthread_t *threads) {

example_wins.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,7 @@ unsigned __stdcall worker(void *arg)
4040

4141
#define join_threads \
4242
for (i = 0; i < nthreads; i++)\
43-
WaitForSingleObject(threads[i], INFINITE);\
44-
printf("current size= %d\n", (int) lfqueue_size(&myq) )
43+
WaitForSingleObject(threads[i], INFINITE)
4544
/*
4645
#define detach_thread_and_loop \
4746
for (i = 0; i < nthreads; i++)\

0 commit comments

Comments
 (0)