delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/03/10/10:25:32

Date: Mon, 10 Mar 1997 17:14:14 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Paul Derbyshire <ao950 AT FreeNet DOT Carleton DOT CA>
cc: djgpp AT delorie DOT com
Subject: Re: Buffered stdio and ANSI
In-Reply-To: <5g0cg5$t6k@freenet-news.carleton.ca>
Message-ID: <Pine.SUN.3.91.970310170937.29057D-100000@is>
MIME-Version: 1.0

On 10 Mar 1997, Paul Derbyshire wrote:

> I notice a lot of people are very puzzlled by DJGPP's buffered STDIO
> functions. It seems peculiar to me, since stdio functions are ANSI
> standardized, that their functioning would vary so significantly depending
> on compiler platform.

I suspect this is because many DJGPP users have previous experience with 
real-mode compilers which are much more aggressive about flushing the 
buffers.  In protected mode, it makes sense to minimize actual writes 
because they involve a mode switch which eats up a lot of cycles.  AFAIK, 
the DJGPP behavior is closer to what you'd see on Unix, but most people 
here got their initial experience elsewhere.

A lot of books which teach C are also sloppy in this respect (it seems 
that their authors only used a real-mode DOS compiler).

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019