diff options
author | kib <kib@FreeBSD.org> | 2014-06-09 03:38:03 +0000 |
---|---|---|
committer | kib <kib@FreeBSD.org> | 2014-06-09 03:38:03 +0000 |
commit | e15884d6df140228c1e2db4ca751565a6933e1f5 (patch) | |
tree | 7c2316986992954183c7ec9c2758a423c606c097 /secure/usr.bin/openssl/man/dgst.1 | |
parent | 7f8a65c9fc018bdfb897ec396fdb4f936ac9bb1f (diff) | |
download | FreeBSD-src-e15884d6df140228c1e2db4ca751565a6933e1f5.zip FreeBSD-src-e15884d6df140228c1e2db4ca751565a6933e1f5.tar.gz |
Change the nblock mutex, protecting the needsbuffer buffer deficit
flags, to rwlock. Lock it in read mode when used from subroutines
called from buffer release code paths.
The needsbuffer is now updated using atomics, while read lock of
nblock prevents loosing the wakeups from bufspacewakeup() and
bufcountadd() in getnewbuf_bufd_help().
In several interesting loads, needsbuffer flags are never set, while
buffers are reused quickly. This causes brelse() and bqrelse() from
different threads to content on the nblock. Now they take nblock in
read mode, together with needsbuffer not needing an update, allowing
higher parallelism.
Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks
Diffstat (limited to 'secure/usr.bin/openssl/man/dgst.1')
0 files changed, 0 insertions, 0 deletions