X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f Date: Wed, 22 Dec 2004 21:13:19 +0200 From: "Eli Zaretskii" Sender: halo1 AT zahav DOT net DOT il To: djgpp AT delorie DOT com Message-ID: <01c4e85a$Blat.v2.2.2$7134c180@zahav.net.il> Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=ISO-8859-1 X-Mailer: emacs 21.3.50 (via feedmail 8 I) and Blat ver 2.2.2 In-reply-to: <20041221212942.746d7b90.lijon@kymatica.com> (message from Jonatan Liljedahl on Tue, 21 Dec 2004 21:29:42 -0200) Subject: Re: DMA and PIO (was Re: Problems with timer interrupt chaining and SmartDrv) References: <01c4e368$Blat.v2.2.2$592f6a00 AT zahav DOT net DOT il> <41c5fcca DOT sandmann AT clio DOT rice DOT edu> <01c4e6ce$Blat.v2.2.2$be0d2340 AT zahav DOT net DOT il> <41c73a4d$0$176$cc7c7865 AT news DOT luth DOT se> <01c4e717$Blat.v2.2.2$a07fa340 AT zahav DOT net DOT il> <41c7daa5$0$180$cc7c7865 AT news DOT luth DOT se> <01c4e795$Blat.v2.2.2$6e49f320 AT zahav DOT net DOT il> <20041221212942 DOT 746d7b90 DOT lijon AT kymatica DOT com> Reply-To: djgpp AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > Date: Tue, 21 Dec 2004 21:29:42 -0200 > From: Jonatan Liljedahl > > > > >> "cat file >/dev/null"? > > > > > > > This reads _and_ writes the file. I want something that just > > > > reads it. > > > > > > It doesn't write it to disk. At least I hope so. > > > > In fact, it doesn't do anything it all: it is smart enough to see that > > stdout is redirected to the null device, and exits immediately. So > > it's no good for a test I wanted to do. > > That's not true. At least not on my system (Linux 2.6.6 with cat version > 5.2.1 (coreutils)). > cat just reads the file until end or user interrupt. I was talking about a native Windows build of cat, not a Linux build. Perhaps the reason is different from what I said, but the fact remains that the Windows port exits in less than 1 second when its stdout is redirected to the null device. The input file is 750MB long, so it cannot be reading all that in less than a second. wc on the same machine takes 20 seconds to read that same file.