Path: news.cs.au.dk!news.net.uni-c.dk!uninett.no!howland.erols.net!netnews.com!news.maxwell.syr.edu!nntp2.dejanews.com!nnrp1.dejanews.com!not-for-mail From: Andrew Klaassen Newsgroups: comp.lang.beta Subject: Speeding up BETA Date: Tue, 04 May 1999 02:41:06 GMT Organization: Deja News - The Leader in Internet Discussion Lines: 35 Message-ID: <7glmo2$6di$1@nnrp1.dejanews.com> NNTP-Posting-Host: 207.229.35.33 X-Article-Creation-Date: Tue May 04 02:41:06 1999 GMT X-Http-User-Agent: Mozilla/3.04 (X11; I; Linux 2.2.4 i486) X-Http-Proxy: 1.0 x3.dejanews.com:80 (Squid/1.1.22) for client 207.229.35.33 Xref: news.cs.au.dk comp.lang.beta:11916 On my machine, this program: .... ---program:descriptor--- (# myputtext: @puttext; do (for 1 000 000 repeat ''->myputtext; for) #) runs at about twice the speed of this program: .... ---program:descriptor--- (# do (for 1 000 000 repeat ''->puttext; for) #) I tried a few other built-in BETA patterns; the same was true for all of them. (Some of them - the ones that don't have to print to the screen - ran at about ten times the speed.) Are there good reasons _not_ to use a single object instantiated from a built-in pattern, like the above, in "real" programs? Thanks! -----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own