changeset 123:5f180dc8d84e intel-fix

intel fix.
author kono
date Mon, 24 Mar 2003 03:05:54 +0900
parents b884271bcab2
children f52805504ffa
files .gdbinit .gdbinit.powerpc Makefile mc-code-ia32.c mc-code-powerpc.c mc-parse.c
diffstat 6 files changed, 10 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/.gdbinit	Mon Mar 24 01:28:02 2003 +0900
+++ b/.gdbinit	Mon Mar 24 03:05:54 2003 +0900
@@ -1,5 +1,5 @@
 tb main
-r -s test/basic.c
+r -s test/tmp7.c
 define regs 
 printf "pc =%08x lr =%08x r0 =%08x r1 =%08x r3= %08x r4= %08x\n",$pc,$lr,$r0,$r1,$r3,$r4
 printf "r10=%08x r11=%08x r12=%08x r13=%08x r14=%08x r15=%08x\n",$r10,$r11,$r12,$r13,$r14,$r15
--- a/.gdbinit.powerpc	Mon Mar 24 01:28:02 2003 +0900
+++ b/.gdbinit.powerpc	Mon Mar 24 03:05:54 2003 +0900
@@ -1,5 +1,5 @@
 tb main
-r -s mc-parse.c
+r -s test/basic.c
 define regs 
 printf "pc =%08x lr =%08x r0 =%08x r1 =%08x r3= %08x r4= %08x\n",$pc,$lr,$r0,$r1,$r3,$r4
 printf "r10=%08x r11=%08x r12=%08x r13=%08x r14=%08x r15=%08x\n",$r10,$r11,$r12,$r13,$r14,$r15
--- a/Makefile	Mon Mar 24 01:28:02 2003 +0900
+++ b/Makefile	Mon Mar 24 03:05:54 2003 +0900
@@ -49,10 +49,10 @@
 
 check: $(MC)
 	-gcc $(TARGET).c -o b.out
-	-b.out > $(TARGET).gcc.out
-	-$(MC) -s $(TARGET).c
+	-./b.out > $(TARGET).gcc.out
+	-./$(MC) -s $(TARGET).c
 	-gcc $(TARGET).s
-	-a.out > $(TARGET).$(MC).out
+	-./a.out > $(TARGET).$(MC).out
 	-diff  $(TARGET).gcc.out $(TARGET).$(MC).out
 
 tar :
--- a/mc-code-ia32.c	Mon Mar 24 01:28:02 2003 +0900
+++ b/mc-code-ia32.c	Mon Mar 24 03:05:54 2003 +0900
@@ -1264,7 +1264,7 @@
 int
 code_csvalue()
 {
-    return creg; /* for switch value */
+    return rname[creg]; /* for switch value */
 }
 
 void
@@ -1272,7 +1272,7 @@
 {
     /* used in dosiwtch() */
     if(chk) return;
-    use_register(creg,rname[csreg],0);
+    use_register(creg,csreg,0);
     printf("\tcmpl $%d,%s\n",e,register_name(creg,0));
 }
 
--- a/mc-code-powerpc.c	Mon Mar 24 01:28:02 2003 +0900
+++ b/mc-code-powerpc.c	Mon Mar 24 03:05:54 2003 +0900
@@ -469,6 +469,7 @@
     free_all_register();
     max_reg_var=-1; max_freg_var=-1;
     reg_sp = 0;
+    freg_sp = 0;
     text_mode();
 }
 
--- a/mc-parse.c	Mon Mar 24 01:28:02 2003 +0900
+++ b/mc-parse.c	Mon Mar 24 03:05:54 2003 +0900
@@ -861,7 +861,8 @@
 	    }
 	    args += size_of_int;
 	} else {
-	    if (n->dsp==0)
+	    /* if (n->dsp==0) (argument list in ADECL is useless, type
+               list can be found in type ) */
 		n->dsp = args;
 	    args += sz;
 	}