🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.ti.explorer
Article #142

Re: PDL

#142
From: James Rice
Date: Tue, 28 Nov 1989 18:55
29 lines
1518 bytes
Yes, I have had similar problems.  In case you don't know
about it there's a programatic way of making sure that you
grow the pdl you want, rather than pushing the resume key
all of the time, called eh:require-pdl-room, which you
call in the process whose pdls you want to grow.

I've noticed two main causes for excessive PDL use.

a) Running interpreted code.  This may sound silly but it
   often requires 10X as much stack to interpret your
   code than to run it compiled.

b) Not taking advantage of tail-recursion optimization.
   The TI compiler is pretty good at this but only if you
   (proclaim '(optimize (safety 0))) [!!!].  It is usually
   possible to recode simplistically written, non
   tail-recursive functions in a tail recursive manner.

A good tactic to use is to break into your program as it
runs and to look at which functions are on the stack
(don't just use c-b, since this will not show all of the
calls to the interpreter.  It is usually the case that
there are only a few offending functions taking up all of
the room.  These can usually be fixed up in some way.




Rice.
Technical Details
Message-ID: <2837271304-7028914@KSL-EXP-6>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!tut.cis.ohio-state.edu!ucbvax!SUMEX-AIM.STANFORD.EDU!Rice

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!tut.cis.ohio-state.edu!ucbvax!SUMEX-AIM.STANFORD.EDU!Rice
From: Rice@SUMEX-AIM.STANFORD.EDU (James Rice)
Newsgroups: comp.sys.ti.explorer
Subject: Re: PDL
Message-ID: <2837271304-7028914@KSL-EXP-6>
Date: 28 Nov 89 18:55:04 GMT
Sender: daemon@ucbvax.BERKELEY.EDU
Distribution: inet
Organization: The Internet
Lines: 29