In perl.git, the branch smoke-me/jhi/tsa has been created

<http://perl5.git.perl.org/perl.git/commitdiff/d15226d730ce7076b97446dba392affab215e996?hp=0000000000000000000000000000000000000000>

        at  d15226d730ce7076b97446dba392affab215e996 (commit)

- Log -----------------------------------------------------------------
commit d15226d730ce7076b97446dba392affab215e996
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Wed Nov 18 21:25:04 2015 -0500

    analysis cannot tell that the thread->mutex was locked
    
    It was locked in S_ithread_create() - in case it returned a non-NULL thread.
    
    threads.xs:1161:9: warning: releasing mutex 'thread->mutex' that was not 
held [-Wthread-safety-analysis]
            MUTEX_UNLOCK(&thread->mutex);

M       dist/threads/threads.xs

commit 293a5e9914f557454c15712782c76bdd950a45d9
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Wed Nov 18 21:18:37 2015 -0500

    analysis does not like mutex being either held or released
    
    threads.xs:1020:1: warning: mutex 'thread->mutex' is not held on every path 
through here [-Wthread-safety-analysis]
    }
    ^

M       dist/threads/threads.xs

commit 585bab8e3561896b194006033b7834ccb9738a2d
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Tue Nov 17 22:15:09 2015 -0500

    annotate S_ithread_create create_destruct_mutex use
    
    If the pool is passed in, and the create_destruct_mutex unlocked also
    on success (so that all the unlocks happen in S_ithread_create()),
    the create_destruct_mutex use can be annotated.
    
    threads.xs:757:9: warning: releasing mutex 
'my_poolp->create_destruct_mutex' th
    at was not held [-Wthread-safety-analysis]
            MUTEX_UNLOCK(&MY_POOL.create_destruct_mutex);
    
    threads.xs:1000:9: warning: releasing mutex 
'my_poolp->create_destruct_mutex' t
    hat was not held [-Wthread-safety-analysis]
            MUTEX_UNLOCK(&MY_POOL.create_destruct_mutex);
    
    threads.c:1319:1: warning: mutex 'my_poolp->create_destruct_mutex' is not 
held on every path through here [-Wthread-safety-analysis]
    }
    ^

M       dist/threads/threads.xs

commit 9b41a4024c21398fc59954662f3d567a711c5fca
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Sat Nov 14 09:09:38 2015 -0500

    annotate S_ithread_count_inc mutex use
    
    No warnings issued, but a clear case for annotations.

M       dist/threads/threads.xs

commit 23db5f243f9b8fa2d23de5508e6b0191d8cd5e05
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Thu Nov 5 19:13:22 2015 -0500

    annotate S_ithread_free mutex use
    
    threads.xs:276:13: warning: releasing mutex 'thread->mutex' that was not 
held [-Wthread-safety-analysis]
                      MUTEX_UNLOCK(&thread->mutex);
    
    threads.xs:282:5: warning: releasing mutex 'thread->mutex' that was not 
held [-Wthread-safety-analysis]
              MUTEX_UNLOCK(&thread->mutex);
    
    threads.xs:394:1: warning: mutex 'thread->mutex' is still held at the end of
          function [-Wthread-safety-analysis]
    }
    
    threads.xs:677:1: warning: mutex 'thread->mutex' is still held at the end of
          function [-Wthread-safety-analysis]
    }

M       dist/threads/threads.xs

commit 59a3298ddc7cc25c096c79f18a2e9e794f39d4ba
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Thu Nov 5 18:15:35 2015 -0500

    split off the $0 setting so mutex use can be annotated
    
    No warnings were emitted since the use of the PL_dollarzero_mutex
    was correctly bracketed by mutex lock and unlock, but by splitting
    off the code and annotating it is more likely to stay correct.

M       mg.c

commit d65ec4590968c7bd4b0b75c2cfbbb148d76fd4f7
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Thu Nov 5 19:00:01 2015 -0500

    cleanup the mutex lock/unlock use of PerlIOStdio_close
    
    Before: clang -Wthread-safety found the flow quite suspect:
    one conditional mutex lock, with two conditional unlocks.
    The code *looked* like the being okay logic-wise now, but
    rather fragile, so let's make it clearer and more solid
    by hoisting the locking earlier.
    
    This is a fd close, this should not be a performance sensitive spot.
    
    And it's in PerlIOStdio, so it should be pretty dead anyway.
    
    perlio.c:3283:18: warning: mutex 'PL_perlio_mutex' is not held on every 
path through here [-Wthread-safety-analysis]
            result = PerlSIO_fclose(stdio);
    
    perlio.c:3299:6: warning: releasing mutex 'PL_perlio_mutex' that was not 
held [-Wthread-safety-analysis]
                MUTEX_UNLOCK(&PL_perlio_mutex);

M       perlio.c

commit 0178e640b2d38c82a434b09792d4dcac53f3514c
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Thu Nov 5 18:58:56 2015 -0500

    annotate the mutex use of S_more_refcounted_fds
    
    perlio.c:2232:2: warning: releasing mutex 'PL_perlio_mutex' that was not 
held [-Wthread-safety-analysis]
            MUTEX_UNLOCK(&PL_perlio_mutex);

M       perlio.c

commit ea1dff635f249ece5b92e07a43c8b9c7be12abea
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Thu Nov 5 18:57:58 2015 -0500

    annotate the mutex use of atfork_lock and atfork_unlock
    
    util.c:2729:1: warning: mutex 'PL_perlio_mutex' is still held at the end of 
function [-Wthread-safety-analysis]
    }
    
    util.c:2729:1: warning: mutex 'PL_op_mutex' is still held at the end of 
function [-Wthread-safety-analysis]
    }
    
    util.c:2739:5: warning: releasing mutex 'PL_perlio_mutex' that was not held 
[-Wthread-safety-analysis]
        MUTEX_UNLOCK(&PL_perlio_mutex);
    
    util.c:2744:5: warning: releasing mutex 'PL_op_mutex' that was not held 
[-Wthread-safety-analysis]
        OP_REFCNT_UNLOCK;

M       util.c

commit 3d8d58058f8d79ec4ff86d4004dca7e33c620766
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Thu Nov 5 18:57:17 2015 -0500

    annotate the acquire/release of PL_op_mutex
    
    op.c:1190:1: warning: mutex 'PL_op_mutex' is still held at the end of 
function
    }
    
    op.c:1199:5: warning: releasing mutex 'PL_op_mutex' that was not held
        OP_REFCNT_UNLOCK;

M       op.c

commit d7e11043ed77c1fd6b95cdf44d91d91a94088752
Author: Jarkko Hietaniemi <j...@iki.fi>
Date:   Thu Nov 5 18:52:20 2015 -0500

    clang thread safety annotations
    
    http://clang.llvm.org/docs/ThreadSafetyAnalysis.html
    
    Static (compile-time) annotations for declaring the multithreaded
    behavior of functions, variables, and capabilities (like mutexes).
    Available since about clang 3.4.
    
    ./Configure -des -Dusedevel -Dusethreads -Dcc=clang 
-Accflags='-Wthread-safety'
    
    clang -Wthread-safety then checks the validity of the annotations.

M       perl.h
M       thread.h
M       util.c
-----------------------------------------------------------------------

--
Perl5 Master Repository

Reply via email to