Import Alan Cox's /usr/src/sys/kern/sys_pipe.c 1.171. This rips out
authorMatthew Dillon <dillon@dragonflybsd.org>
Sun, 28 Mar 2004 08:25:54 +0000 (08:25 +0000)
committerMatthew Dillon <dillon@dragonflybsd.org>
Sun, 28 Mar 2004 08:25:54 +0000 (08:25 +0000)
commitc617badaa88f761220d9c82e7122527dfe871af2
tree488f21d6d0aad653c658d7893414bf02cb2c9c18
parent18bbe476c84ce0ddc7b508590fbb32f8a3de002e
Import Alan Cox's /usr/src/sys/kern/sys_pipe.c 1.171.  This rips out
writer-side KVA mappings and replaces them with writer-side vm_page wiring
(left intact from before) plus reader-side SF_BUF copies.

Import 1.141, which is a simple patch which removes a blocking condition
when space is available in the pipe's write buffer which was causing
non-blocking I/O select-based writes to spin-wait unnecessarily.  1.171
rips out writer-side KVA mappings and replaces them

Import FreeBSD-5.x's uiomove_fromphys(), which sys_pipe.c now uses.  This
procedure could become very useful in a number of DragonFly subsystems.

This greatly improves PIPE performance for the direct-mapped case (moderate
to large reads and writes).  Additionally, recent scheduler fixes greatly
improve PIPE performance for both the direct-mapped and small-buffer cases.

NOTE: wired page limits for pipes have not yet been imported, and the heavy
use of sf_buf's may require some tuning in the many-pipes case.

    BLKSIZE BEFORE AFTER
MBytes/s MBytes/s Tests on AMD64/3200+ FN85 MB
    ------- ------ ------ (64KB L1, 1MB L2)
    256KB 1900 2200
     64KB 1800 2200
     16KB 1650 2500-3000
      8KB 1400 2300
      4KB 1300 1400-1500 (note 1)

    note 1: The 4KB case is not a direct-write case, the results are due to
    the scheduler fixes only.

Obtained-from: FreeBSD-5.x / FreeBSD's Alan Cox
sys/conf/files.i386
sys/i386/i386/uio_machdep.c [new file with mode: 0644]
sys/kern/sys_pipe.c
sys/platform/pc32/i386/uio_machdep.c [new file with mode: 0644]
sys/sys/pipe.h
sys/sys/sfbuf.h
sys/sys/uio.h