*** empty log message ***
[fw/sdcc] / src / xa51 / main.c
index b893bf79f6d97508e5be1f50f1a69d318f97ab43..8875d3e7b964b4c88d0985e0afca507e54c1dda1 100755 (executable)
@@ -143,16 +143,18 @@ _xa51_genAssemblerPreamble (FILE * of)
   mainExists->block=0;
 
   if ((mainExists=findSymWithLevel(SymbolTab, mainExists))) {
-    fprintf (of, "\t.area CSEG\t(CODE)\n");
+    fprintf (of, "\t.area GSINIT\t(CODE)\n");
     fprintf (of, "__interrupt_vect:\n");
     fprintf (of, "\t.dw\t0x8f00\n");
     fprintf (of, "\t.dw\t__sdcc_gsinit_startup\n");
     fprintf (of, "\n");
     fprintf (of, "__sdcc_gsinit_startup:\n");
-    fprintf (of, "\tmov.b\t_SCR,#0x01\t; page zero mode\n");
+    //fprintf (of, ";\tmov.b\t_SCR,#0x01\t; page zero mode\n");
+    fprintf (of, "\t.db 0x96,0x48,0x40,0x01\n");
     fprintf (of, "\tmov\tr7,#0x%04x\n", options.stack_loc);
     fprintf (of, "\tcall\t_external_startup\n");
     _xa51_genXINIT(of);
+    fprintf (of, "\t.area CSEG\t(CODE)\n");
     fprintf (of, "\tcall\t_main\n");
     fprintf (of, "\treset\t;main should not return\n");
   }
@@ -198,7 +200,7 @@ static const char *_linkCmd[] =
 /* $3 is replaced by assembler.debug_opts resp. port->assembler.plain_opts */
 static const char *_asmCmd[] =
 {
-  "xa_rasm", "$l", "$3", "$1.xa", NULL
+  "xa_rasm", "$l", "$3", "$1.asm", NULL
 };
 
 /* Globals */
@@ -218,7 +220,7 @@ PORT xa51_port =
     "",                                /* Options with debug */
     "",                                /* Options without debug */
     0,
-    ".xa",
+    ".asm",
     NULL                       /* no do_assemble function */
   },
   {
@@ -285,9 +287,9 @@ PORT xa51_port =
   TRUE, // use_dw_for_init
   0,                           /* leave lt */
   0,                           /* leave gt */
-  0,                           /* transform <= to ! > */
-  0,                           /* transform >= to ! < */
-  0,                           /* transform != to !(a == b) */
+  1,                           /* transform <= to ! > */
+  1,                           /* transform >= to ! < */
+  1,                           /* transform != to !(a == b) */
   0,                           /* leave == */
   FALSE,                        /* No array initializer support. */
   cseCostEstimation,