daemon@decwrl.UUCP (02/09/84)
From: vogon::goodenough (Jeff Goodenough, IPG) In reply to sytek!blk (aka B<), Ray Miller probably did just what I did - wrote a disassembler and disassembled the ROM. From then on it's just a detective game - following leads like the pointer table in low ROM (near A000) which is in order of token values, and picking out likely looking bits of code that play with the FAC. Then you try it out and see if it works. As we English say, "the proof of the pudding is in the eating". Or maybe you *do* have inside info, Ray? Also, any response on my earlier comment regarding variable storage? Another point: could you check that floating subtract? My reading of it is that it is an *inverse* subtract (like divide), so that F1 := F2-F1, not F1-F2. But I call FSUB at $B850 (instead of B853) which loads the SF variable into F2 first. Maybe it moves things around as well, but I don't have my ROM listing with me to check. Jeff Goodenough DEC, Basingstoke, (olde) Hampshire, UK. UUCP: ... decvax!decwrl!rhea!vogon!goodenough ...allegra!decwrl!rhea!vogon!goodenough ... ucbvax!decwrl!rhea!vogon!goodenough ARPA: decwrl!rhea!vogon!goodenough@Berkeley decwrl!rhea!vogon!goodenough@SU-Shasta
miller@uiucdcs.UUCP (miller ) (02/15/84)
#R:decwrl:-553200:uiucdcs:36100044:000:727 uiucdcs!miller Feb 15 00:50:00 1984 By golly Jeff, you're right! It is F1 = F2 - F1 on the c64 floating point routines (and not F1 - F2). My mistake there. Actually, subtraction is very short, so I have reproduced it below for those that are interested: ; subtraction ; ORG $B853 LDA 102 ;get sign of F1 EOR# $FF ;complement F1 sign STA 102 ;replace so F1=-1*F1 EOR 110 ;compare F1, F2 signs STA 111 ;set sign compare flag for addition LDA 97 ;setup for add too JMP $B86A ;goto addition subroutine I wrote a note last week on the variable storage question so I won't reproduce that here again. Thanks for pointing that out, Jeff. Sorry for the mixup... A. Ray Miller Univ Illinois