cvs commit: src/sys/dev/random randomdev_soft.c
Robert Watson
rwatson at FreeBSD.org
Sat Oct 9 15:09:03 PDT 2004
On Sat, 9 Oct 2004, Robert Watson wrote:
> - When reaping harvested entries from the queue, move all entries from
> the queue at once, and when done with them, insert them all into a
> thread-local queue for processing; then insert them all into the
> empty fifo at once. This reduces O(4n) mutex operations to O(2)
> mutex operations per wakeup.
Right now we do a slightly harmful O(2N) walk of the records to move them
to a thread-local queue. It would be very nice to have an O(1) tailq (and
other list) "move them all" operation to move all entries to a local head.
This would also be useful when dealing with other work queues in worker
threads, such as bio queues, etc.
Robert N M Watson FreeBSD Core Team, TrustedBSD Projects
robert at fledge.watson.org Principal Research Scientist, McAfee Research
More information about the cvs-src
mailing list