diff options
author | Malcolm Beattie <mbeattie@sable.ox.ac.uk> | 1998-02-27 18:06:41 +0000 |
---|---|---|
committer | Malcolm Beattie <mbeattie@sable.ox.ac.uk> | 1998-02-27 18:06:41 +0000 |
commit | dce16143c60882f40eb787063b9483c00bb82139 (patch) | |
tree | dcb3c30695829781cc03b666fe1d2ae5eeda975c /perl.c | |
parent | d22150111e6fba142fe332ab0f2c6233df82013c (diff) | |
download | perl-dce16143c60882f40eb787063b9483c00bb82139.tar.gz |
Make refcounts atomic for threading (dependent on appropriate
arch-dependent and compiler-dependent definitions in atomic.h
or else falls back to a global mutex to protect refcounts).
p4raw-id: //depot/perl@598
Diffstat (limited to 'perl.c')
-rw-r--r-- | perl.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -130,6 +130,9 @@ perl_construct(register PerlInterpreter *sv_interp) COND_INIT(&eval_cond); MUTEX_INIT(&threads_mutex); COND_INIT(&nthreads_cond); +#ifdef EMULATE_ATOMIC_REFCOUNTS + MUTEX_INIT(&svref_mutex); +#endif /* EMULATE_ATOMIC_REFCOUNTS */ thr = init_main_thread(); #endif /* USE_THREADS */ |