Mercurial > hg > CbC > old > device
diff mc-code-mips.c @ 314:2e1012a8852a
MIPS GNUC 2 define fix
author | kono |
---|---|
date | Tue, 15 Jun 2004 00:24:42 +0900 |
parents | f73b93de216a |
children | 84df3dd8cc3d |
line wrap: on
line diff
--- a/mc-code-mips.c Tue Jun 15 00:11:26 2004 +0900 +++ b/mc-code-mips.c Tue Jun 15 00:24:42 2004 +0900 @@ -445,21 +445,26 @@ lvar_address(e2,reg); } + +// va_start, va_arg is wrong, use va_mips.h + char *init_src = "\ -#define __builtin_va_list int\n\ -#define __builtin_va_start(ap,arg) ap=(((int)(&arg))+sizeof(arg))\n\ -#define __builtin_va_arg(ap,type) (*((type *)ap)++)\n\ +/* #define __builtin_va_list int */\n\ +/* #define __builtin_va_start(ap,arg) ap=(((int)(&arg))+sizeof(arg)) */\n\ +/* #define __builtin_va_arg(ap,type) (*((type *)ap)++) */\n\ #define __builtin_next_arg(arg) ap=((void *)(&arg)),va_arg(ap,typeof(arg))\n\ #define __mips__ 1\n\ #define __LITTLE_ENDIAN__ 1\n\ #define __STDC__ 1\n\ #define __SIZE_TYPE__ int\n\ #define __externsion__\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\ #define __PTRDIFF_TYPE__ int\n\ #define __GNUC__ 2\n\ +#define __const const\n\ #define alloca __builtin_alloca\n\ ";