From: keie Date: Tue, 4 Jun 1985 10:21:15 +0000 (+0000) Subject: 1 - Changed %D into %ld. X-Git-Tag: release-5-5~5464 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=be932f0f5bc9036024747718261eb8afb7ec6576;p=ack.git 1 - Changed %D into %ld. 2 - Adapted to the new linker. --- diff --git a/mach/m68k2/cg/mach.c b/mach/m68k2/cg/mach.c index 65fb301e4..3c5848c1e 100644 --- a/mach/m68k2/cg/mach.c +++ b/mach/m68k2/cg/mach.c @@ -23,7 +23,7 @@ static char rcsid[] = "$Header$"; * machine dependent back end routines for the Motorola 68000 */ -#define IEEEFLOAT +/* #define IEEEFLOAT */ #ifdef IEEEFLOAT #include "FP.h" @@ -58,7 +58,7 @@ con_mult(sz) word sz; { if (sz != 4) fatal("bad icon/ucon size"); - fprintf(codefile,".long %s\n",str); + fprintf(codefile,".data4 %s\n",str); } #ifdef IEEEFLOAT @@ -86,7 +86,7 @@ con_float() sz = argval; if (sz!= 4 && sz!= 8) { - sprintf(mesg,"con_float(): bad fcon size %d %D\nstr: %s\n\0", + sprintf(mesg,"con_float(): bad fcon size %d %ld\nstr: %s\n\0", sz,sz,str); fatal(mesg); } @@ -104,7 +104,7 @@ con_float() #endif IEEEFLOAT while ( sz ) { - fprintf(codefile,"\t.word 0x%x,0x%x !float test %s\n", + fprintf(codefile,"\t.data2 0x%x,0x%x !float test %s\n", (int)(*l)&0xFFFF,(int)(*l>>16)&0xFFFF,str); sz -=4 ; l++; @@ -235,7 +235,7 @@ regreturn() prolog(nlocals) full nlocals; { - fprintf(codefile,"tst.b -%D(sp)\nlink\ta6,#-%D\n",nlocals+40,nlocals); + fprintf(codefile,"tst.b -%ld(sp)\nlink\ta6,#-%ld\n",nlocals+40,nlocals); } @@ -264,8 +264,8 @@ mes(type) word type ; { char *segname[] = { - ".text", /* SEGTXT */ - ".data", /* SEGCON */ - ".data", /* SEGROM */ - ".bss" /* SEGBSS */ + ".sect .text", /* SEGTXT */ + ".sect .data", /* SEGCON */ + ".sect .rom", /* SEGROM */ + ".sect .bss" /* SEGBSS */ }; diff --git a/mach/m68k2/cg/mach.h b/mach/m68k2/cg/mach.h index 62a2e1fda..92a56218e 100644 --- a/mach/m68k2/cg/mach.h +++ b/mach/m68k2/cg/mach.h @@ -4,11 +4,11 @@ #define newilb(x) fprintf(codefile,"%s:\n",x) #define newdlb(x) fprintf(codefile,"%s:\n",x) #define dlbdlb(x,y) fprintf(codefile,"%s = %s\n",x,y) -#define newlbss(l,x) fprintf(codefile,"%s:.space\t%D\n",l,x); +#define newlbss(l,x) fprintf(codefile,"%s:.space\t%ld\n",l,x); #define pop_fmt "(sp)+" -#define cst_fmt "%D" -#define off_fmt "%D" +#define cst_fmt "%ld" +#define off_fmt "%ld" #define ilb_fmt "I%03x%x" #define dlb_fmt "_%d" #define hol_fmt "hol%d" @@ -17,11 +17,11 @@ #define arg_off "8+%d(a6)" #define hol_off "%d+hol%d" -#define con_cst(x) fprintf(codefile,".short\t%d\n",x) -#define con_ilb(x) fprintf(codefile,".long\t%s\n",x) -#define con_dlb(x) fprintf(codefile,".long\t%s\n",x) +#define con_cst(x) fprintf(codefile,".data2\t%d\n",x) +#define con_ilb(x) fprintf(codefile,".data4\t%s\n",x) +#define con_dlb(x) fprintf(codefile,".data4\t%s\n",x) -#define modhead "" +#define modhead ".sect .text;.sect .rom;.sect .data;.sect .bss\n" #define id_first '_' #define BSS_INIT 0