2012/7/16 Kai Tietz:
> Well,
>
> I am fine by this patch, but I would love to get additional a testcase
> added for it.
>
> So patch is ok with a testcase.

Log in attachment.



-- 
Regards,
niXman
___________________________________________________
Dual-target(32 & 64 bit) MinGW compilers for 32 and 64 bit Windows:
http://sourceforge.net/projects/mingwbuilds/
rm -f *.dll
rm -f *.lib
rm -f pthread.h
rm -f semaphore.h
rm -f sched.h
rm -f *.a
rm -f *.e
rm -f *.i
rm -f *.o
rm -f *.so
rm -f *.obj
rm -f *.pdb
rm -f *.exe
rm -f *.pass
rm -f *.fail
rm -f *.x
rm -f *.bench
rm -f *.static
rm -f *.log
Copying ../.libs/libwinpthread.dll.a
Copying ../.libs/libwinpthread-1.dll
make -k TEST=GC CC=-gcc XXCFLAGS="-D__CLEANUP_C" all-pass
make[1]: Entering directory `/usr/home/niXman/build/tests'
Compiling runall.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o runall.exe runall.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running runall
./runall
usage: runall <dir>
Passed
Compiling sizes.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o sizes.exe sizes.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running
./sizes.exe > SIZES.GC
Sizes of winpthreads structs
-------------------------------
                     pthread_t    4
               pthread_attr_t_   16
              pthread_mutex_t_   28
          pthread_mutexattr_t_    4
           pthread_spinlock_t_   12
            pthread_barrier_t_   36
        pthread_barrierattr_t_    4
                pthread_key_t_    4
               pthread_cond_t_  108
           pthread_condattr_t_    4
             pthread_rwlock_t_   32
         pthread_rwlockattr_t_    4
               pthread_once_t_    4
                   sched_param    4
-------------------------------
Passed
Compiling loadfree.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o loadfree.exe loadfree.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
loadfree.c: In function 'main':
loadfree.c:61:13: warning: unused variable 'hinst' [-Wunused-variable]
Preparing loadfree TESTS
Running loadfree
./loadfree
Passed
Compiling self1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o self1.exe self1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running self1
./self1
Passed
Compiling mutex5.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex5.exe mutex5.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex5
./mutex5
Passed
Compiling mutex1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex1.exe mutex1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex1
./mutex1
Passed
Compiling mutex1e.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex1e.exe mutex1e.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex1e
./mutex1e
Passed
Compiling mutex1n.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex1n.exe mutex1n.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex1n
./mutex1n
Passed
Compiling mutex1r.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex1r.exe mutex1r.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex1r
./mutex1r
Passed
Compiling semaphore1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o semaphore1.exe semaphore1.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running semaphore1
./semaphore1
thread: sem_trywait 1: expecting error EAGAIN: got EAGAIN
thread: ok 2
main: sem_trywait 1: expecting error EAGAIN: got EAGAIN
main: ok 2
Passed
Compiling semaphore2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o semaphore2.exe semaphore2.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running semaphore2
./semaphore2
Passed
Compiling semaphore3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o semaphore3.exe semaphore3.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running semaphore3
./semaphore3
Complete
Passed
Compiling condvar1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar1.exe condvar1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running condvar1
./condvar1
Passed
Compiling condvar1_1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar1_1.exe condvar1_1.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running condvar1_1
./condvar1_1
Passed
Compiling condvar1_2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar1_2.exe condvar1_2.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling join2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o join2.exe join2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling create1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o create1.exe create1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling mutex2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex2.exe mutex2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex2
./mutex2
Try lock
Mutex locked
Mutex unlocked
Mutex destroyed
Passed
Running create1
./create1
Passed
Running join2
./join2
Passed
Running condvar1_2
./condvar1_2
Passed
Compiling condvar2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar2.exe condvar2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
condvar2.c: In function 'main':
condvar2.c:90:15: warning: unused variable 'NANOSEC_PER_MILLISEC' 
[-Wunused-variable]
Running condvar2
./condvar2
Passed
Compiling condvar2_1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar2_1.exe condvar2_1.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running condvar2_1
./condvar2_1
Passed
Compiling exit1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o exit1.exe exit1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running exit1
./exit1
Passed
Compiling create2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o create2.exe create2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running create2
./create2
Assertion failed: (washere == 1), file create2.c, line 104
make[1]: *** [create2.pass] Error 1
Compiling reuse1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o reuse1.exe reuse1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling reuse2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o reuse2.exe reuse2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling equal1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o equal1.exe equal1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running equal1
./equal1
Passed
Compiling kill1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o kill1.exe kill1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running kill1
./kill1
Passed
Compiling valid1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o valid1.exe valid1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling join1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o join1.exe join1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running join1
./join1
Passed
Running valid1
./valid1
Passed
Compiling valid2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o valid2.exe valid2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running valid2
./valid2
Passed
Compiling exit2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o exit2.exe exit2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running exit2
./exit2
Passed
Compiling exit3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o exit3.exe exit3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running exit3
./exit3
Passed
Compiling exit4.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o exit4.exe exit4.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running exit4
./exit4
result=1
result=1
result=1
result=1
Passed
Compiling exit5.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o exit5.exe exit5.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running exit5
./exit5
Passed
Compiling join0.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o join0.exe join0.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running join0
./join0
Passed
Compiling detach1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o detach1.exe detach1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running detach1
./detach1
Passed
Compiling join3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o join3.exe join3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running join3
./join3
Passed
Compiling mutex2r.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex2r.exe mutex2r.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex2r
./mutex2r
Passed
Compiling mutex2e.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex2e.exe mutex2e.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex2e
./mutex2e
Passed
Compiling mutex3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex3.exe mutex3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex3
./mutex3
Passed
Compiling mutex3r.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex3r.exe mutex3r.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex3r
./mutex3r
Passed
Compiling mutex3e.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex3e.exe mutex3e.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex3e
./mutex3e
Passed
Compiling mutex4.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex4.exe mutex4.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex4
./mutex4
*** 0==0

*** 0==0

*** 1==1

*** 1==1

Passed
Compiling mutex6.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex6.exe mutex6.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex6
./mutex6
lockCount = 1
Passed
Compiling mutex6n.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex6n.exe mutex6n.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex6n
./mutex6n
Passed
Compiling mutex6e.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex6e.exe mutex6e.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex6e
./mutex6e
Passed
Compiling mutex6r.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex6r.exe mutex6r.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex6r
./mutex6r
Passed
Compiling mutex6s.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex6s.exe mutex6s.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex6s
./mutex6s
Passed
Compiling mutex6es.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex6es.exe mutex6es.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex6es
./mutex6es
Passed
Compiling mutex6rs.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex6rs.exe mutex6rs.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex6rs
./mutex6rs
Passed
Compiling mutex7.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex7.exe mutex7.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex7
./mutex7
Passed
Compiling mutex7n.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex7n.exe mutex7n.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex7n
./mutex7n
Passed
Compiling mutex7e.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex7e.exe mutex7e.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex7e
./mutex7e
Passed
Compiling mutex7r.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex7r.exe mutex7r.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex7r
./mutex7r
Passed
Compiling mutex8.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex8.exe mutex8.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex8
./mutex8
Passed
Compiling mutex8n.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex8n.exe mutex8n.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex8n
./mutex8n
Passed
Compiling mutex8e.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex8e.exe mutex8e.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex8e
./mutex8e
Passed
Compiling mutex8r.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o mutex8r.exe mutex8r.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running mutex8r
./mutex8r
Passed
Compiling count1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o count1.exe count1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running count1
./count1
Passed
Compiling once1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o once1.exe once1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running once1
./once1
Passed
Compiling once2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o once2.exe once2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running once2
./once2
Passed
Compiling once3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o once3.exe once3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running once3
./once3
Passed
Compiling once4.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o once4.exe once4.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running once4
./once4
CPU count (reduced): 3
CPU count: 4
Passed
Compiling self2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o self2.exe self2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running self2
./self2
Passed
Compiling cancel1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cancel1.exe cancel1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running cancel1
./cancel1
Passed
Compiling cancel2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cancel2.exe cancel2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running cancel2
./cancel2
Passed
Compiling semaphore4.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o semaphore4.exe semaphore4.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running semaphore4
./semaphore4
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
r = 0 0 EINVAL 22
Passed
Compiling semaphore4t.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o semaphore4t.exe semaphore4t.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running semaphore4t
./semaphore4t
Passed
Compiling semaphore5.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o semaphore5.exe semaphore5.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running semaphore5
./semaphore5
Passed
Compiling barrier1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o barrier1.exe barrier1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running barrier1
./barrier1
Passed
Compiling barrier2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o barrier2.exe barrier2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running barrier2
./barrier2
Passed
Compiling barrier3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o barrier3.exe barrier3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running barrier3
./barrier3
Passed
Compiling barrier4.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o barrier4.exe barrier4.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running barrier4
./barrier4
Barrier height = 1
Barrier height = 2
Barrier height = 3
Barrier height = 4
Barrier height = 5
Barrier height = 6
Barrier height = 7
Barrier height = 8
Barrier height = 9
Barrier height = 10
Barrier height = 11
Barrier height = 12
Barrier height = 13
Barrier height = 14
Barrier height = 15
Barrier height = 16
Passed
Compiling barrier5.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o barrier5.exe barrier5.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running barrier5
./barrier5
Threads=1, Barrier height=1
Threads=2, Barrier height=2
Threads=3, Barrier height=3
Threads=4, Barrier height=4
Threads=5, Barrier height=5
Threads=6, Barrier height=6
Threads=7, Barrier height=7
Threads=8, Barrier height=8
Threads=9, Barrier height=9
Threads=10, Barrier height=10
Threads=11, Barrier height=10
Threads=12, Barrier height=10
Threads=13, Barrier height=10
Threads=14, Barrier height=10
Threads=15, Barrier height=10
Passed
Compiling barrier6.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o barrier6.exe barrier6.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running barrier6
./barrier6
Barrier height = 1, Total threads 1
Barrier height = 2, Total threads 2
Barrier height = 2, Total threads 3
Barrier height = 3, Total threads 4
Barrier height = 3, Total threads 5
Barrier height = 4, Total threads 6
Barrier height = 4, Total threads 7
Barrier height = 5, Total threads 8
Barrier height = 5, Total threads 9
Barrier height = 6, Total threads 10
Barrier height = 6, Total threads 11
Barrier height = 7, Total threads 12
Barrier height = 7, Total threads 13
Barrier height = 8, Total threads 14
Barrier height = 8, Total threads 15
Barrier height = 9, Total threads 16
Barrier height = 9, Total threads 17
Barrier height = 10, Total threads 18
Barrier height = 10, Total threads 19
Barrier height = 11, Total threads 20
Barrier height = 11, Total threads 21
Barrier height = 12, Total threads 22
Barrier height = 12, Total threads 23
Barrier height = 13, Total threads 24
Barrier height = 13, Total threads 25
Barrier height = 14, Total threads 26
Barrier height = 14, Total threads 27
Barrier height = 15, Total threads 28
Barrier height = 15, Total threads 29
Barrier height = 16, Total threads 30
Barrier height = 16, Total threads 31
Passed
Compiling tsd1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o tsd1.exe tsd1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running tsd1
./tsd1
Passed
Compiling tsd2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o tsd2.exe tsd2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
tsd2.c:86:28: warning: initialization makes integer from pointer without a cast 
[enabled by default]
Running tsd2
./tsd2
Passed
Compiling delay1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o delay1.exe delay1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running delay1
./delay1
Passed
Compiling delay2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o delay2.exe delay2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
delay2.c: In function 'func':
delay2.c:54:3: warning: initialization from incompatible pointer type [enabled 
by default]
delay2.c:54:3: warning: (near initialization for '_pthread_cup.func') [enabled 
by default]
Running delay2
./delay2
Passed
Compiling eyal1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o eyal1.exe eyal1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
eyal1.c: In function 'do_work_unit':
eyal1.c:145:8: warning: variable 'i' set but not used 
[-Wunused-but-set-variable]
Running eyal1
./eyal1
01230412563475896012738901245637894012567893410256
78395402678193526784012395678014325679801423569078
01230213130213442413202131320213013442431560560653
36533224611436464537605765700572521108999394906772

 0      92144
 1      92144
 2      95893
 3     111476
 4      78407
 5      74040
 6      78407
 7      60309
 8      44931
 9      54923
Passed
Compiling condvar3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar3.exe condvar3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running condvar3
./condvar3
Passed
Compiling condvar3_1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar3_1.exe condvar3_1.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running condvar3_1
./condvar3_1
awk = 11
sig = 11
tot = 19
Passed
Compiling condvar3_2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar3_2.exe condvar3_2.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running condvar3_2
./condvar3_2
Passed
Compiling condvar3_3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar3_3.exe condvar3_3.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running condvar3_3
./condvar3_3
Passed
Compiling condvar4.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar4.exe condvar4.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running condvar4
./condvar4
Passed
Compiling condvar5.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar5.exe condvar5.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running condvar5
./condvar5
Passed
Compiling condvar6.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar6.exe condvar6.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running condvar6
./condvar6
Passed
Compiling condvar7.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar7.exe condvar7.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling cleanup1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cleanup1.exe cleanup1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling cleanup0.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cleanup0.exe cleanup0.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling cancel5.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cancel5.exe cancel5.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling cancel3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cancel3.exe cancel3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Compiling context1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o context1.exe context1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running context1
./context1
Passed
Running cancel3
./cancel3
Passed
Running cancel5
./cancel5
Passed
Running cleanup0
./cleanup0
Passed
Running cleanup1
./cleanup1
Passed
Running condvar7
./condvar7
Passed
Compiling condvar8.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar8.exe condvar8.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
condvar8.c: In function 'mythread':
condvar8.c:58:3: warning: initialization from incompatible pointer type 
[enabled by default]
condvar8.c:58:3: warning: (near initialization for '_pthread_cup.func') 
[enabled by default]
Running condvar8
./condvar8
Passed
Compiling condvar9.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o condvar9.exe condvar9.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
condvar9.c: In function 'mythread':
condvar9.c:63:3: warning: initialization from incompatible pointer type 
[enabled by default]
condvar9.c:63:3: warning: (near initialization for '_pthread_cup.func') 
[enabled by default]
Running condvar9
./condvar9
Passed
Compiling errno1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o errno1.exe errno1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running errno1
./errno1
Passed
Compiling rwlock1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock1.exe rwlock1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock1
./rwlock1
Passed
Compiling rwlock2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock2.exe rwlock2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock2
./rwlock2
Passed
Compiling rwlock3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock3.exe rwlock3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock3
./rwlock3
Passed
Compiling rwlock4.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock4.exe rwlock4.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock4
./rwlock4
Passed
Compiling rwlock5.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock5.exe rwlock5.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock5
./rwlock5
Passed
Compiling rwlock6.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock6.exe rwlock6.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock6
./rwlock6
10 10 20
Passed
Compiling rwlock7.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock7.exe rwlock7.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock7
./rwlock7
..................................................
Thread 0 found changed elements 761806 times
Thread 1 found changed elements 766380 times
Thread 2 found changed elements 763714 times
Thread 3 found changed elements 763239 times
Thread 4 found changed elements 763004 times

00: seed 42, updates 64605, reads 935395
01: seed 8, updates 64340, reads 935660
02: seed 16, updates 64634, reads 935366
03: seed 18, updates 64742, reads 935258
04: seed 71, updates 64106, reads 935894

data 00: value 4, 72450 updates
data 01: value 4, 42225 updates
data 02: value 4, 40286 updates
data 03: value 4, 42020 updates
data 04: value 4, 41194 updates
data 05: value 4, 41742 updates
data 06: value 4, 42510 updates
322427 thread updates, 322427 data updates

start: 1342542095/756, stop: 1342542100/145, duration:4389
Passed
Compiling rwlock8.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock8.exe rwlock8.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock8
./rwlock8
..................................................
Thread 0 found changed elements 76179 times
Thread 1 found changed elements 74711 times
Thread 2 found changed elements 70224 times
Thread 3 found changed elements 75126 times
Thread 4 found changed elements 76753 times

00: seed 42, updates 6458, reads 93542
01: seed 8, updates 6439, reads 93561
02: seed 16, updates 6307, reads 93693
03: seed 18, updates 6602, reads 93398
04: seed 71, updates 6476, reads 93524

data 00: value 2, 7300 updates
data 01: value 2, 4225 updates
data 02: value 2, 4050 updates
data 03: value 2, 4233 updates
data 04: value 2, 4059 updates
data 05: value 2, 4182 updates
data 06: value 2, 4233 updates
32282 thread updates, 32282 data updates

start: 1342542100/555, stop: 1342542101/57, duration:502
Passed
Compiling rwlock2_t.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock2_t.exe rwlock2_t.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock2_t
./rwlock2_t
Passed
Compiling rwlock3_t.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock3_t.exe rwlock3_t.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock3_t
./rwlock3_t
Passed
Compiling rwlock4_t.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock4_t.exe rwlock4_t.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock4_t
./rwlock4_t
Passed
Compiling rwlock5_t.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock5_t.exe rwlock5_t.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock5_t
./rwlock5_t
Passed
Compiling rwlock6_t.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock6_t.exe rwlock6_t.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock6_t
./rwlock6_t
Passed
Compiling rwlock6_t2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o rwlock6_t2.exe rwlock6_t2.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running rwlock6_t2
./rwlock6_t2
Passed
Compiling cancel4.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cancel4.exe cancel4.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running cancel4
./cancel4
Passed
Compiling cancel6a.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cancel6a.exe cancel6a.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running cancel6a
./cancel6a
Passed
Compiling cancel6d.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cancel6d.exe cancel6d.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running cancel6d
./cancel6d
Passed
Compiling cancel7.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cancel7.exe cancel7.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running cancel7
./cancel7
Passed
Compiling cancel8.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cancel8.exe cancel8.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
cancel8.c: In function 'Win32thread':
cancel8.c:42:3: warning: initialization from incompatible pointer type [enabled 
by default]
cancel8.c:42:3: warning: (near initialization for '_pthread_cup.func') [enabled 
by default]
Running cancel8
./cancel8
Passed
Compiling cleanup2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cleanup2.exe cleanup2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running cleanup2
./cleanup2
Passed
Compiling cleanup3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cleanup3.exe cleanup3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running cleanup3
./cleanup3
Passed
Compiling priority1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o priority1.exe priority1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running priority1
./priority1
Using GetThreadPriority
 Set value  Get value
       -15        -15
       -14         -2
       -13         -2
       -12         -2
       -11         -2
       -10         -2
        -9         -2
        -8         -2
        -7         -2
        -6         -2
        -5         -2
        -4         -2
        -3         -2
        -2         -2
        -1         -1
         0          0
         1          1
         2          2
         3          2
         4          2
         5          2
         6          2
         7          2
         8          2
         9          2
        10          2
        11          2
        12          2
        13          2
        14          2
        15         15
Using pthread_getschedparam
 Set value  Get value Win priority
       -15        -15        -15
       -14        -14         -2
       -13        -13         -2
       -12        -12         -2
       -11        -11         -2
       -10        -10         -2
        -9         -9         -2
        -8         -8         -2
        -7         -7         -2
        -6         -6         -2
        -5         -5         -2
        -4         -4         -2
        -3         -3         -2
        -2         -2         -2
        -1         -1         -1
         0          0          0
         1          1          1
         2          2          2
         3          3          2
         4          4          2
         5          5          2
         6          6          2
         7          7          2
         8          8          2
         9          9          2
        10         10          2
        11         11          2
        12         12          2
        13         13          2
        14         14          2
        15         15         15
Passed
Compiling priority2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o priority2.exe priority2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running priority2
./priority2
...............................Passed
Compiling inherit1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o inherit1.exe inherit1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running inherit1
./inherit1
.......Passed
Compiling spin1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o spin1.exe spin1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running spin1
./spin1
Passed
Compiling spin2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o spin2.exe spin2.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running spin2
./spin2
Passed
Compiling spin3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o spin3.exe spin3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running spin3
./spin3
Passed
Compiling spin4.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o spin4.exe spin4.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running spin4
./spin4
Passed
Compiling exception1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o exception1.exe exception1.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running exception1
./exception1
Test N/A for this compiler environment.
Passed
Compiling exception2.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o exception2.exe exception2.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running exception2
./exception2
Test N/A for this compiler environment.
Passed
Compiling exception3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o exception3.exe exception3.c 
-I./include -L../outlib -lwinpthread -lsupc++ -lws2_32
Running exception3
./exception3
Test N/A for this compiler environment.
Passed
Compiling cancel9.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o cancel9.exe cancel9.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
cancel9.c: In function 'test_udp':
cancel9.c:86:14: warning: variable 'bytes' set but not used 
[-Wunused-but-set-variable]
cancel9.c: In function 'test_wait':
cancel9.c:148:9: warning: variable 'dwEvent' set but not used 
[-Wunused-but-set-variable]
Running cancel9
./cancel9
Cancel sleeping thread.
Cancel waiting thread.
Cancel blocked thread (blocked on network I/O).
Passed
Compiling create3.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o create3.exe create3.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
create3.c: In function 'main':
create3.c:102:11: warning: variable 'result' set but not used 
[-Wunused-but-set-variable]
Running create3
./create3
You should see an application memory write error message
Passed
Compiling stress1.exe
-gcc -O3 -UNDEBUG -Wall -D__CLEANUP_C -o stress1.exe stress1.c -I./include 
-L../outlib -lwinpthread -lsupc++ -lws2_32
Running stress1
./stress1
Signals sent = 1000
Wait timeouts = 468
Signals taken = 532
Bias = 3
Timeout = 10
Passed
make[1]: Target `all-pass' not remade because of errors.
make[1]: Leaving directory `/usr/home/niXman/build/tests'
mingw32-make: *** [GC] Error 2
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to