Adapted to new assembler syntax
authorceriel <none@none>
Tue, 20 Jan 1987 10:04:32 +0000 (10:04 +0000)
committerceriel <none@none>
Tue, 20 Jan 1987 10:04:32 +0000 (10:04 +0000)
mach/z8000/cg/mach.c
mach/z8000/cg/mach.h

index e6221a5..6879094 100644 (file)
@@ -41,7 +41,7 @@ con_mult(sz) word sz; {
 
        if (sz != 4)
                fatal("bad icon/ucon size");
-       fprintf(codefile,"\t.long %s\n", str);
+       fprintf(codefile,"\t.data4 %s\n", str);
 }
 
 con_float() {
@@ -49,7 +49,7 @@ con_float() {
 static int been_here;
        if (argval != 4 && argval != 8)
                fatal("bad fcon size");
-       fprintf(codefile,"\t.long ");
+       fprintf(codefile,"\t.data4 ");
        if (argval == 8)
                fprintf(codefile,"F_DUM, ");
        fprintf(codefile,"F_DUM\n");
@@ -100,8 +100,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 */
 };
index 868cb72..35f6f3c 100644 (file)
@@ -8,17 +8,18 @@
 
 #define cst_fmt         "%d"
 #define off_fmt         "%d"
-#define ilb_fmt         "I%03x%x"
+#define ilb_fmt         "I%x_%x"
 #define dlb_fmt         "_%d"
 #define hol_fmt         "hol%d"
 
 #define hol_off         "%d+hol%d"
 
-#define con_cst(x)      fprintf(codefile,"\t.word %d\n",x)
-#define con_ilb(x)      fprintf(codefile,"\t.word %s\n",x)
-#define con_dlb(x)      fprintf(codefile,"\t.word %s\n",x)
+#define con_cst(x)      fprintf(codefile,"\t.data2 %d\n",x)
+#define con_ilb(x)      fprintf(codefile,"\t.data2 %s\n",x)
+#define con_dlb(x)      fprintf(codefile,"\t.data2 %s\n",x)
 
-#define modhead         ""
+#define modhead         ".sect .text; .sect .rom; .sect .data; .sect .bss\n"
+
+#define fmt_id(sf,st)  sprintf(st,"_%s", sf)
 
-#define id_first        '_'
 #define BSS_INIT        0