git: nmalloc - Fix depot race - this should fix remaining issues

看板DFBSD_commit作者時間15年前 (2010/10/12 03:32), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/1
commit ebe0d3612773443a8bf0158503b9597cf70acd03 Author: Matthew Dillon <dillon@apollo.backplane.com> Date: Mon Oct 11 12:21:32 2010 -0700 nmalloc - Fix depot race - this should fix remaining issues with firefox. * nmalloc was accidently calling the libc _pthread_spin_lock() stub even when threaded, causing all depot operations to race. No actual lock was being acquired. Change it over to the internal _SPINLOCK() API. * Expand libthread_xu's base spinlocks from 128 to 256 and use those for the depot lock. Note that the depot[] array can be upwards of 80 elements so lets not take any chances. Reported-by: Pierre Abbat <phma@phma.optus.nu>, others Summary of changes: lib/libc/stdlib/nmalloc.c | 18 +++++++++--------- lib/libthread_xu/thread/thr_spinlock.c | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/ebe0d3612773443a8bf0158503b9597cf70acd03 -- DragonFly BSD source repository
文章代碼(AID): #1CisOy7o (DFBSD_commit)