diff mc-code-mips.c @ 569:1fcad06b264a

gcc4 (ia32)
author kono
date Thu, 12 Jan 2006 01:54:14 +0900
parents d6ff45d719a5
children 7e0076617c76
line wrap: on
line diff
--- a/mc-code-mips.c	Wed Jan 11 18:30:24 2006 +0900
+++ b/mc-code-mips.c	Thu Jan 12 01:54:14 2006 +0900
@@ -23,11 +23,11 @@
 #define __builtin_next_arg(arg)  ap=((void *)(&arg)),va_arg(ap,typeof(arg))\n\
 #define __mips__ 1\n\
 #define __LITTLE_ENDIAN__ 1\n\
-#define __inline__\n\
+#define __inline__ inline\n\
 #define __STDC__ 1\n\
 #define __SIZE_TYPE__ int\n\
 #define __extension__\n\
-#define __attribute__(a)\n\
+// #define __attribute__(a)\n\
 #define __flexarr\n\
 #define __WCHAR_TYPE__ int\n\
 #define __alignof__(type) (sizeof(type)==1?1:sizeof(type)==2?2:sizeof(type)<=4?4:8)\n\
@@ -2092,7 +2092,7 @@
     NMTBL *fn = 0;
     int jmp = 0;
     int complex_;
-    int pnargs,preg_arg,pfreg_arg;
+    int pnargs=0,preg_arg=0,pfreg_arg=0;
     int stargs;
 
     special_lvar = -1;
@@ -4226,7 +4226,7 @@
 int
 drexpr(int e1, int e2,int l1, int op,int cond)
 {
-    int op1;
+    int op1=0;
     if (!cond) {
 	switch(op) {
 	    case FOP+GT:
@@ -4879,6 +4879,7 @@
 
     if (car(e)==LCONST) v = lcadr(e);
     else if (car(e)==CONST) v = cadr(e);
+    else { v=0; error(-1); }
 
     switch(op) {
     case LMUL: case LUMUL:
@@ -5531,8 +5532,8 @@
 set_bitsz(int type,int *pbitpos, int *pbitsize,
 	int *psign,int *pbitsz,int *palign,int *pl)
 { 
-    int sign=0,bitsz; 
-    int align,l=0;
+    int sign=0,bitsz=0; 
+    int align=4,l=0;
     *pbitpos = cadr(caddr(type));
     *pbitsize = caddr(caddr(type));
     switch(cadr(type)) {  /* value type */
@@ -5568,7 +5569,7 @@
     int bitsize,bitpos0;
     set_bitsz(type,&bitpos0,&bitsize,&sign,&bitsz,&align,&l);
 
-    if (bitsize>bitsz) { error(BTERR); bitsize = i; }
+    if (bitsize>bitsz) { error(BTERR); bitsize = bitsz; }
 
     /* bfd means previous bit field bit offset */
     if (bitpos) {