Xref: utzoo alt.sources.amiga:233 comp.sys.amiga.programmer:3381 Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uwm.edu!linac!att!pacbell.com!tandem!zorch!amiga0!mykes From: mykes@amiga0.SF-Bay.ORG (Mike Schwartz) Newsgroups: alt.sources.amiga,comp.sys.amiga.programmer Subject: Re: Short Hello World Message-ID: Date: 8 May 91 18:47:08 GMT References: <1991Apr30.213936.22878@ux1.cso.uiuc.edu> <1991May2.102554.8679@cs.umu.se> <1200@cbmger.UUCP> <1991May4.134045.7550@cs.umu.se> <1205@cbmger.UUCP> Organization: Amiga makes it possible Lines: 44 In article <1205@cbmger.UUCP> 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 Another note: You probably want to also use a specific version number, especially if you want to do 2.0 specific things. For example, the 2.0 Dos library lets you do SetFunction(), while the 1.3 doesn't. -- **************************************************** * I want games that look like Shadow of the Beast * * but play like Leisure Suit Larry. * ****************************************************