dc.w SpriteX8_and-DrawIconTable dc.w SpriteX8_or-DrawIconTable dc.w SpriteX8_xor-DrawIconTable
Je sens que si je vais mettre la compilation séparée, j'aurai encore plus souvent ce problème.
dc.w SpriteX8_and-DrawIconTable dc.w SpriteX8_or-DrawIconTable dc.w SpriteX8_xor-DrawIconTable
PpHd :
>Et au passage, l'utilisation de words pour des références entre sections est à qualifier de bogue à mon avis. Mais je n'ai jamais eu qu'une seule section, moi.
Flash.asm line 171 pedrom.asm line 45 2254 move.w #((\FlashWrite_ExecuteInRam_End-\FlashWrite_ExecuteInRam)/2-1),d0 ^ Relocatability error. Flash.asm line 273 pedrom.asm line 45 2356 move.w #((\FlashErase_ExecuteInRam_End-\FlashErase_ExecuteInRam)/2-1),d0 ^ Relocatability error. Flash.asm line 1001 pedrom.asm line 45 3124 move.w #(TIBReceivEnd-TIBReceiv)/4,d0 ^ Relocatability error. library.asm line 27 pedrom.asm line 64 13049 dc.w (PedoMLibExportTableEnd-PedoMLibExportTable-2)/2 ^ Relocatability error. shell2.asm line 408 pedrom.asm line 76 25523 addq.l #WriteModeStr-ReadModeStr,a1 ; default: 32767 36436write ^ Operand size error. ^ Relocatability error. shell2.asm line 415 pedrom.asm line 76 25530 addq.l #AppendModeStr-WriteModeStr,a1 ; mode: append ^ Operand size error. ^ Relocatability error. Vectors.asm line 284 pedrom.asm line 86 32129 move.w #(__offRAMEnd-__offRAM)/2-1,d1 ^ Relocatability error. RomCalls.h line 17 pedrom.asm line 105 35379 dc.l (ROMCALLS_TABLE_END-ROMCALLS_TABLE)/4 ^ Relocatability error. End of assembly - 10 errors were found.
Relocs Saved by Branch Optimization: 31 Relocs Saved by Move Optimization: 10 Relocs Savable by F-Line Jumps: 1178 Space Savable by Range-Cutting: 16 Bytes
Flanker
: et puis, je ne suis pas sûr que ça économise vraiment les 16o
Billy Charvet :
Je pense aussi. (Mais à la fin d'un .??u, il y a un checksum 16 bits dez tout l'éuquivalent
du tib, ça ça peut se faire par le linker, en revanche une signature cryptée ou un hash
pourrait me bloquer... je ne suis pas sûr qu'on pourra envoyer des OS par TIGL/ TI Connect un jour.
Kevin > Je me suis heurté exactement aux mêmes erreurs (mais tu les a résolues on dirait) Si tu peux me mailer la source de ce PedRom utilisable avec ld-tigcc, ça m'arrangerait bien.
diff -Nur orig/C/BITMAP.ASM ld-tigcc/C/BITMAP.ASM --- orig/C/BITMAP.ASM Tue Dec 31 23:31:18 1996 +++ ld-tigcc/C/BITMAP.ASM Mon May 3 18:49:00 2004 @@ -528,3 +528,34 @@ movem.l -24(a6),#$478 unlk a6 rts + +;void DrawIcon (short x, short y, const void *Icon, short Attr) +DrawIcon: + move.w 4(a7),d0 ; x + move.w 6(a7),d1 ; y + move.l 8(a7),a0 ; Icon + move.w 12(a7),d2 ; ATTR +DrawIcon_reg + cmpi.w #3,d2 + bne.s \NoShade + ; It seems that it should do set or erase a pixel according to a tiny cpt + ; I don't want to support it. Maybe in the future ? + moveq #1,d2 ; ATTR = A_NORMAL +\NoShade: ; ATTR = A_REVERSE doesn't work directly + cmpi.w #2,d2 + bhi.s \Ret + move.l CURRENT_SCREEN,-(a7) + move.w #2,-(a7) + pea (a0) + move.w #16,-(a7) + move.w d1,-(a7) + move.w d0,-(a7) + add.w d2,d2 + move.w DrawIconTable(pc,d2.w),d2 + jsr DrawIconTable(pc,d2.w) + lea 16(a7),a7 +\Ret: rts +DrawIconTable: + dc.w SpriteX8_and-DrawIconTable + dc.w SpriteX8_or-DrawIconTable + dc.w SpriteX8_xor-DrawIconTable diff -Nur orig/Graph.asm ld-tigcc/Graph.asm --- orig/Graph.asm Wed Jan 1 00:21:24 1997 +++ ld-tigcc/Graph.asm Mon May 3 18:48:44 2004 @@ -2110,37 +2110,6 @@ movem.l (a7)+,d3-d5/a2-a3 rts -;void DrawIcon (short x, short y, const void *Icon, short Attr) -DrawIcon: - move.w 4(a7),d0 ; x - move.w 6(a7),d1 ; y - move.l 8(a7),a0 ; Icon - move.w 12(a7),d2 ; ATTR -DrawIcon_reg - cmpi.w #3,d2 - bne.s \NoShade - ; It seems that it should do set or erase a pixel according to a tiny cpt - ; I don't want to support it. Maybe in the future ? - moveq #1,d2 ; ATTR = A_NORMAL -\NoShade: ; ATTR = A_REVERSE doesn't work directly - cmpi.w #2,d2 - bhi.s \Ret - move.l CURRENT_SCREEN,-(a7) - move.w #2,-(a7) - pea (a0) - move.w #16,-(a7) - move.w d1,-(a7) - move.w d0,-(a7) - add.w d2,d2 - move.w DrawIconTable(pc,d2.w),d2 - jsr DrawIconTable(pc,d2.w) - lea 16(a7),a7 -\Ret: rts -DrawIconTable: - dc.w SpriteX8_and-DrawIconTable - dc.w SpriteX8_or-DrawIconTable - dc.w SpriteX8_xor-DrawIconTable - ;void DrawFkey (short x, short y, short fkey_no, short Attr) DrawFkey: clr.w -(a7) Binary files orig/MAKE89.PIF and ld-tigcc/MAKE89.PIF differ diff -Nur orig/Make89.bat ld-tigcc/Make89.bat --- orig/Make89.bat Tue Dec 31 23:29:08 1996 +++ ld-tigcc/Make89.bat Mon May 3 20:55:10 2004 @@ -1,8 +1,5 @@ @del pedrom89.tib @del pedrom89.sav -@ttstrip ..\Preos\stdlib.9xz stdlib.bin -@a68k -t -i..\Preos\Src -iC pedrom.asm -lC:\temp\listing.txt -vTI89 +@..\ttstrip Preos\stdlib.9xz stdlib.bin +@tigcc -v --optimize-code --flash-os --outputbin -WA,-i..\Preos,-iC,-vTI89 pedrom.asm @del stdlib.bin -@maketib pedrom.o -@del pedrom.o -@ren pedrom.tib pedrom89.tib \ No newline at end of file diff -Nur orig/PedroM.asm ld-tigcc/PedroM.asm --- orig/PedroM.asm Tue Dec 31 23:53:18 1996 +++ ld-tigcc/PedroM.asm Mon May 3 18:42:42 2004 @@ -31,7 +31,7 @@ ROM_BASE EQU $200000 ; $400000 for ti92+ / $200000 for 89 & V200 endif ********************************************************** - RORG ROM_BASE+$012088 + section "_st1" include "Vectors.h" ; Vectors's table include "Mem.h" ; Macros usefull for defining struct include "Const.h" ; Constants @@ -60,7 +60,7 @@ *** $418000-$419FFF 8K [read protected] *** *** *** *********************************************************** - RORG ROM_BASE+$1A000 + section ".text" include "library.asm" ; Export API include "Printf.asm" ; Printf functions include "Kernel.asm" ; Kernel functions Binary files orig/Preos/STDLIB.89Z and ld-tigcc/Preos/STDLIB.89Z differ Binary files orig/Preos/Stdlib.9xz and ld-tigcc/Preos/Stdlib.9xz differ diff -Nur orig/Strings.asm ld-tigcc/Strings.asm --- orig/Strings.asm Tue Dec 31 23:13:46 1996 +++ ld-tigcc/Strings.asm Mon May 3 18:36:18 2004 @@ -145,14 +145,6 @@ ST_StrC dc.b "USE left right + [ENTER]=OK AND [ESC]=CANCEL",0 ST_StrD dc.b "USE [2ND] [KEYS] OR [ESC]=CANCEL",0 -BT_NONE_str dc.b "None",0 -BT_OK_str dc.b "Enter=OK",0 -BT_SAVE_str dc.b "Enter=SAVE",0 -BT_YES_str dc.b "Enter=YES",0 -BT_CANCEL_str dc.b "Esc=CANCEL",0 -BT_NO_str dc.b "ESC=NO",0 -BT_GOTO_str dc.b "Enter=GOTO",0 - AppsDialogTitle dc.b "APPLICATIONS & MODE",0 AppsText dc.b "APPS/MODE menu not implemented.",10,"Wait for next release.",0 diff -Nur orig/Window.asm ld-tigcc/Window.asm --- orig/Window.asm Wed Jan 1 01:23:08 1997 +++ ld-tigcc/Window.asm Mon May 3 18:36:22 2004 @@ -1243,6 +1243,14 @@ dc.w BT_NO_str-DrawStaticButtonTable dc.w BT_GOTO_str-DrawStaticButtonTable +BT_NONE_str dc.b "None",0 +BT_OK_str dc.b "Enter=OK",0 +BT_SAVE_str dc.b "Enter=SAVE",0 +BT_YES_str dc.b "Enter=YES",0 +BT_CANCEL_str dc.b "Esc=CANCEL",0 +BT_NO_str dc.b "ESC=NO",0 +BT_GOTO_str dc.b "Enter=GOTO",0 + ;void WinDrawButton(WINDOW *w, short x, short y, char *str, short width, short height); WinDrawButton: bsr _WinSetSystemVar Binary files orig/pedrom-89.tib and ld-tigcc/pedrom-89.tib differ Binary files orig/pedrom89.tib and ld-tigcc/pedrom89.tib differ
(user macro) line 3 Dialog.asm line 1275 pedrom.asm line 50 7482 dc.w Ln_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1276 pedrom.asm line 50 7486 dc.w Exp_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1277 pedrom.asm line 50 7490 dc.w Sin_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1278 pedrom.asm line 50 7494 dc.w Cos_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1279 pedrom.asm line 50 7498 dc.w Tan_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1280 pedrom.asm line 50 7502 dc.w ASin_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1281 pedrom.asm line 50 7506 dc.w ACos_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1282 pedrom.asm line 50 7510 dc.w ATan_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1283 pedrom.asm line 50 7514 dc.w Sqrt_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1284 pedrom.asm line 50 7518 dc.w Int_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1285 pedrom.asm line 50 7522 dc.w Der_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1286 pedrom.asm line 50 7526 dc.w Sigma_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1287 pedrom.asm line 50 7530 dc.w Inv_XRstr-STRINGS ^ Relocatability error. (user macro) line 3 Dialog.asm line 1288 pedrom.asm line 50 7534 dc.w Ans_XRstr-STRINGS ^ Relocatability error. Script.asm line 48 pedrom.asm line 59 14396 moveq #ScriptHeader_end-ScriptHeader_str,d0 ^ Relocatability error.