From owner-freebsd-hackers Mon Apr 30 6:47:12 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from cslab.csie.ntu.edu.tw (cslab.csie.ntu.edu.tw [140.112.30.25]) by hub.freebsd.org (Postfix) with ESMTP id 1842637B422 for ; Mon, 30 Apr 2001 06:46:59 -0700 (PDT) (envelope-from r88074@csie.ntu.edu.tw) Received: from hornets (hornets.csie.ntu.edu.tw [140.112.30.134]) by cslab.csie.ntu.edu.tw (8.9.3/8.9.3) with SMTP id VAA25665; Mon, 30 Apr 2001 21:40:53 +0800 (CST) Message-Id: <200104301340.VAA25665@cslab.csie.ntu.edu.tw> From: "林英超" To: "Alfred Perlstein" Cc: "Freebsd-Hackers" Subject: RE: write() vs aio_write() Date: Mon, 30 Apr 2001 21:39:43 +0800 X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0) In-Reply-To: <20010430063101.Z18676@fw.wintelcom.net> Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG -----Original Message----- From: owner-freebsd-hackers@FreeBSD.ORG [mailto:owner-freebsd-hackers@FreeBSD.ORG]On Behalf Of Alfred Perlstein Sent: Monday, April 30, 2001 9:31 PM To: 林英超 Cc: Freebsd-Hackers Subject: Re: write() vs aio_write() * 林英超 [010430 06:17] wrote: > Dear all: > > Because write() use buffer cache, I want to know whether aio_write() is > better than write() in FreeBSD 4.1 . Is aio_write() > > outperform write() ? Or any related performance comparison between the two > system call ???? aio_write is for doing async aio. meaning you can ask the kernel to move data for you from a memory location to a file descriptor while you proceed on with doing other work. if you don't have any other work to do then aio is probably just going to slow you down. Now I am trying to implement a Proxy Server. I want to use asynchrounos I/O so that the Proxy Server can do other things than blocking on I/O operation. Is it a good idea to use aio_write or aio_read on Proxy Server ??? Thanks a lot Richard_Lin -- -Alfred Perlstein - [alfred@freebsd.org] Daemon News Magazine in your snail-mail! http://magazine.daemonnews.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message