Article View: comp.text.tex
Article #2661Re: Big TeX's -- how hard are they to come by?
From: Piercarlo Grandi
Date: Sat, 12 Sep 1992 22:16
Date: Sat, 12 Sep 1992 22:16
51 lines
3167 bytes
3167 bytes
On 11 Sep 92 07:46:44 GMT, rolfl@karl.uio.no (Rolf Lindgren) said: Nntp-Posting-Host: karl.uio.no rolfl> (Ajay Shah) writes: Shah> I find it hard to appreciate why TeX should not know how to Shah> dynamically allocate RAM on demand. Does this have something to Shah> do with being written in pascal? I seem to recall that new() Shah> returns nil if you are out of memory.. Shah> In any case, where is TeX implementation going in the future? rolfl> When Knuth wrote TeX, he knew what he was doing. This is a rolfl> fundamental assumption, and all arguments pro or con should be rolfl> checked against this. rolfl> Now, Web, I suppose, supports dynamic allocation of memory rolfl> through Pascal's new() operator, whose behavior in extreme cases rolfl> is unspecified and the execution speed of which is compiler rolfl> dependent. Web is not the problem. Knuth wanted TeX to be maximally portable, so he wrote it in Web and in a *subset* of Pascal, one that he thought would be more portable than full Pascal. For some bizarre reason he thought that new() would not be available everywhere, so he avoided its use, and the TeX implementation is based on the assumptions that each record is really an entry in some fixed size table. This is terrible, not just in terms of flexibility (none...) but also in terms of paging, because of the separate, fixed size, memory pools for each record type (on the other hand it helps when one wants to \dump, as one just writes out the contents of those tables, without having to traverse pointer chains). There is a person, Pat Monardo, who has been working on a reimplementation in C of the entire TeX program, one that does use malloc() for allocating record types. I have worked a bit on it, towards the end of making its allocation of memory even more dynamic, but I had to stop that for the past year or so. In the meantime the author has published release 3.3 of his CommonTeX, which is a high quality program, available as: isis.cshl.org:/tex/commontex330.tar.Z I really hope at times that Knuth's TeX just went away. Pascal is passe`, the subset he used is too restricted, and literate programming may not be that great an idea... -- Piercarlo Grandi | JNET: pcg@uk.ac.aber Dept of CS, University of Wales | UUCP: ...!aber-cs!pcg Penglais, Aberystwyth SY23 3BZ, UK | INET: pcg@aber.ac.uk
Technical Details
Message-ID:
<PCG.92Sep12221620@aberdb.aber.ac.uk>Path:
arc1-ca.pugleaf.net!sparky!uunet!charon.amdahl.com!pacbell.com!ames!elroy.jpl.nasa.gov!usc!sol.ctr.columbia.edu!ira.uka.de!math.fu-berlin.de!news.netmbx.de!Germany.EU.net!mcsun!uknet!gdt!aber!aberfa!pcgReferences:
<BuEC6r.B47@news.cso.uiuc.edu> <18p7lpINNc73@almaak.usc.edu> <ROLFL.92Sep11084644@karl.uio.no>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!charon.amdahl.com!pacbell.com!ames!elroy.jpl.nasa.gov!usc!sol.ctr.columbia.edu!ira.uka.de!math.fu-berlin.de!news.netmbx.de!Germany.EU.net!mcsun!uknet!gdt!aber!aberfa!pcg From: pcg@aber.ac.uk (Piercarlo Grandi) Newsgroups: comp.text.tex Subject: Re: Big TeX's -- how hard are they to come by? Message-ID: <PCG.92Sep12221620@aberdb.aber.ac.uk> Date: 12 Sep 92 22:16:20 GMT References: <BuEC6r.B47@news.cso.uiuc.edu> <18p7lpINNc73@almaak.usc.edu> <ROLFL.92Sep11084644@karl.uio.no> Sender: news@aber.ac.uk (USENET news service) Reply-To: pcg@aber.ac.uk (Piercarlo Grandi) Organization: Prifysgol Cymru, Aberystwyth Lines: 51 In-Reply-To: rolfl@karl.uio.no's message of 11 Sep 92 07: 46:44 GMT Nntp-Posting-Host: aberdb