From owner-freebsd-arch@FreeBSD.ORG Thu Feb 14 19:47:37 2013 Return-Path: Delivered-To: arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id D29AF49D for ; Thu, 14 Feb 2013 19:47:37 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) by mx1.freebsd.org (Postfix) with ESMTP id 55A2E9A6 for ; Thu, 14 Feb 2013 19:47:37 +0000 (UTC) Received: from tom.home (kostik@localhost [127.0.0.1]) by kib.kiev.ua (8.14.6/8.14.6) with ESMTP id r1EJlVD9013561 for ; Thu, 14 Feb 2013 21:47:31 +0200 (EET) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.7.4 kib.kiev.ua r1EJlVD9013561 Received: (from kostik@localhost) by tom.home (8.14.6/8.14.6/Submit) id r1EJlVDp013560 for arch@freebsd.org; Thu, 14 Feb 2013 21:47:31 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Thu, 14 Feb 2013 21:47:31 +0200 From: Konstantin Belousov To: arch@freebsd.org Subject: Re: Unmapped I/O Message-ID: <20130214194731.GK2522@kib.kiev.ua> References: <20121219135451.GU71906@kib.kiev.ua> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="XnmMk6h6iXODEPbR" Content-Disposition: inline In-Reply-To: <20121219135451.GU71906@kib.kiev.ua> User-Agent: Mutt/1.5.21 (2010-09-15) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on tom.home X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Feb 2013 19:47:37 -0000 --XnmMk6h6iXODEPbR Content-Type: text/plain; charset=us-ascii Content-Disposition: inline This is an update on the message http://lists.freebsd.org/pipermail/freebsd-arch/2012-December/013672.html The work implements the unmapped kernel I/O buffers, eliminating the overhead of the mapping and IPIs, for most of i/o paths on the UFS volumes. In particular, read(2)/write(2) initiated i/o, including clustered operations and page-ins are unmapped. Also the physio is unmapped if the geom/drivers support it. Only ahci(4) is adopted to provide required support. Most other HBAs which properly use bus_dmamap_load_ccb() can be trivially converted in a way similar to ahci(4), see the changes in the patch. I did not the conversion because I cannot test. I consider the current patch ready to be committed into the HEAD. Some elements of the design were discussed with Jeff Roberson. The patch was tested by Peter Holm, a backport to stable/9 got load testing by Scott Long. I see an ~30% reduction in the system time on reading large files over UFS/ahci on the 4-core HTT machine. The only big stop there is the lack of testing on non-x86 platforms. Marius Strobl pointed out that pmap_copy_pages() for sparc64 is incorrect. For the final commit, I will disable the unmapped buffers on any architecture which was not tested at the time of commit. The patch is available at http://people.freebsd.org/~kib/misc/unmapped.13.patch --XnmMk6h6iXODEPbR Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iQIcBAEBAgAGBQJRHT9TAAoJEJDCuSvBvK1BoP4P/jeOppSvMxn3oUX9/3zLphJw Ho82hRCKt3QBTq9LDRB4h0kMpLZQw5W/l4vqXHcJMSpQ1qJkJQN9K4Wcpc4hs8Sv qgrQfd+CvMukGLUUFFtEJLRkIwxA0wMAI/5U8LFwTjYZ8+OR5Lk2OUVw2m4LvGnn 9fHvqrSnRAIAiDuPYnWklR5uEy0YOmfkq5/vl/kXKWTShE/MBmpfrT2IvpfaIoJR czpfgFkpzqNlIfJEiHhfgQ0Q3P9sTtmdVE7H7F7hvV8F2QNkVySRKy78mcqViGYP kchcIpJQryquZtyEMXT5e1LacediwIR1OUC9jL8kPnCTXGIt9uryQJEFPqGSo4CT h9vsaKG8s+a+yUbPusinXfOj5huCk4V5npygRtPoKhTAqQxgB0W97B+anOsX2PFW PDwz/7mYSuNKc/14v0rdvhqOXOvsSn+RS1AFtds1Kjrt1yHEbocHfoxSYp3/zhtt Xr0itgDorQXZHmQfjrhkbvAL+0c3Z17kpuhROjku4/swVUSDSd0HibkqpBOPOEFQ LXBZfTxQ9LXlfPh8JGwa36/SWqywPVIwqXRJtGRX9TSx64lWWJPGDnlpwTT/ZnPp 6mgk2FbO/s3L7OW4RYudT3Do3ylfUmVZ/LMcjgCstY4yXmMS3uv5qD2FHoKmRuiR YiqwiL3fXZrG1BrJRMz1 =E2h0 -----END PGP SIGNATURE----- --XnmMk6h6iXODEPbR--