Modula2's godawful IO.

Chris Torek chris at mimsy.UUCP
Thu Apr 21 20:25:42 AEST 1988


>In article <942 at unmvax.unm.edu> mike at turing.UNM.EDU.UUCP (Michael
>I. Bushnell) writes:
>>To use printf, it ups your text segment by a whole 2236 bytes. ...

In article <230 at jupiter.olyis.UUCP> ecb at pluto.uucp (Eric Brown) writes:
>Now include the size of the floating point libraries.  On Microsoft 5.0 C,
>calling printf links the floating point emulator, which is about 30K of code.
[stuff deleted]
>Not all the world is a vax, you know.

Conversely, not all the world is an IBM PC with a Microsoft compiler.
It is not difficult[*] to arrange for the linker to pull in a simple
printf() if the rest of the program does not use floating point, and a
full-blown floating point printf if it does.  Just because Microsoft's
implementation is poor (in terms of space, at any rate) is no reason to
castigate printf itself.

-----
[*]What, never?  Well, hardly ever.  The trick is to have the linker
examine the undefined externals for floating-point library references,
and if present, link with `bigprintf.obj'; otherwise it should use
`littleprintf.obj'.  It is just a Small Matter of Programming.
-- 
In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 7163)
Domain:	chris at mimsy.umd.edu	Path:	uunet!mimsy!chris



More information about the Comp.lang.c mailing list