Xref: utzoo alt.sources.amiga:232 comp.sys.amiga.programmer:3376 Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!spool.mu.edu!cs.umn.edu!quest!orbit!pnet51!chucks From: chucks@pnet51.orb.mn.org (Erik Funkenbusch) Newsgroups: alt.sources.amiga,comp.sys.amiga.programmer Subject: Re: Short Hello World Message-ID: <4852@orbit.cts.com> Date: 8 May 91 07:01:42 GMT Article-I.D.: orbit.4852 Sender: news@orbit.cts.com Organization: People-Net [pnet51], Minneapolis, MN. Lines: 47 peterk@cbmger.UUCP (Peter Kittel GERMANY) writes: >In article <1991May4.134045.7550@cs.umu.se> dvljrt@cs.umu.se (Joakim Rosqvist) writes: >>In article <1200@cbmger.UUCP> peterk@cbmger.UUCP (Peter Kittel GERMANY) writes: >>>In article <1991May2.102554.8679@cs.umu.se> dvljrt@cs.umu.se (Joakim Rosqvist) writes: >>>> >>>>Ok, assembler strikes back with this: (56 codesize, 92 executable) >>> >>>Shame on you, you cheated! You do an OpenLib without a CloseLib! >>>Perhaps this explains the difference. >>> >>I did not! It's ok to close a disk-library, but DosLib is in ROM, and >>Closing it is the same as adding NOP's to the code. Anyway, with a >>closelib it will be 60/96 bytes. Still shorter! >>If you don't agree with me, reply in Amiga.programmer... > >Well, we had a lengthy discussion on this in the German sub.sys.amiga >group. We came to the conclusion that it would really be dangerous! >Because, if your Amiga runs long enough and runs such programs in a >tight loop, the use counter of the library will be increased every time. >And, after *some* (:-) time, it will wrap around to zero. And, if it >happens that you have a tight memory situation just in this moment and >exec flushes all unused libs: POOF! I admit, not an everyday scenario, >but sure possible :-). > >You see, there was a related discussion whether you should check for >success of opening dos.library (or which lib was it?) at all, because >theoretically you always will succeed. But also there it was concluded >that you better use the safe way. > >-- >Best regards, Dr. Peter Kittel // E-Mail to \\ Only my personal opinions... >Commodore Frankfurt, Germany \X/ {uunet|pyramid|rutgers}!cbmvax!cbmger!peterk not to mention that there is SOME RAM overhead for opening a library anyways, if you happen to have all memory allocated and then try to open a library.. it won't succeed, that is a MUCH more common occurance. I think commodore should DEFINATELY squelch this rumor that rom calls will always succeed. .--------------------------------------------------------------------------. | UUCP: {amdahl!tcnet, crash}!orbit!pnet51!chucks | "I know he's come back | | ARPA: crash!orbit!pnet51!chucks@nosc.mil | from the dead, but do | | INET: chucks@pnet51.orb.mn.org | you really think he's | |-------------------------------------------------| moved back in?" | | Amiga programmer at large, employment options | Lou Diamond Philips in | | welcome, inquire within. | "The First Power". | `--------------------------------------------------------------------------'