Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!clyde.concordia.ca!nstn.ns.ca!news.cs.indiana.edu!arizona.edu!arizona!dave From: dave@cs.arizona.edu (Dave P. Schaumann) Newsgroups: comp.sys.amiga.programmer Subject: Re: How are some programs SO DAMN SMALL! Message-ID: <869@caslon.cs.arizona.edu> Date: 15 Feb 91 00:51:47 GMT References: <1991Jan20.210328.18087@hoss.unl.edu> <28077.279c3c3f@kuhub.cc.ukans.edu> <91042.125712UH2@psuvm.psu.edu> <91042.134209J56QC@CUNYVM.BITNET> mwm@pa.dec.com (Mike (My Watch Has Windows) Meyer) writes: |In article <865@caslon.cs.arizona.edu> dave@cs.arizona.edu (Dave P. Schaumann) writes: | |I'm afraid he means that he used BASIC to write it. [...] | |No, but I thought about it. | | Is this true? It is very dishonest to claim the size of a (uncompiled) | BASIC program is just the size of the file holding the program. It is | really the size of the program + the size of the interpreter. | |I disagree. It depends on whether or not you have to reload the |interpreter every time you run the program. If that's required, then |you're right - you should count the interpreter. If the interpreter |gets loaded once, the first time you run it, and is always available |after that (unless flushed to free memory), then you're wrong - you've |got what amounts to a shared library. [...] Even if a single copy of the interpreter can be used to execute multiple programs, you still have to count it at least once. Even if you say "resident c:echo", your "echo hello world" still requires the code for echo, even though it is resident, and used for other things. Really, to be strictly accurate, you should include all the AmigaOS support code in your code size, too. The characters "echo hello world" aren't some magic incantation your Amiga instinctively knows what to do with. It takes some kind of shell, which will call c:echo, c:echo, which in turn calls Intuition code. A truely fair measure of how large "echo hello world" is would take into account *all* of the code executed to bring those characters to your screen. If you wanted to get pedantic, you could include the memory required to hold the font used, as well. |[...] |In article <865@caslon.cs.arizona.edu> dave@cs.arizona.edu (Dave P. Schaumann) writes: | | echo "hello world" | | is a program in AmigaShell which is roughly 20 bytes long. Please be careful with author attributations. I did not write this. |Teddies good friend has his two o'clock feast Mike Meyer -- Dave Schaumann | DANGER: Access holes may tear easily. Use of the access | holes for lifting or carrying may result in damage to the dave@cs.arizona.edu | carton and subsequent injury to the user.