Changeset 46579c66 in mainline
- Timestamp:
- 2006-03-16T17:17:41Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 79aeb43b
- Parents:
- 41fa6f2
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
arch/mips32/include/arg.h
r41fa6f2 r46579c66 32 32 #include <arch/types.h> 33 33 34 typedef struct va_list {35 int pos;36 __u8 *last;37 } va_list;38 39 #define va_start(ap, lst) \40 (ap).pos = sizeof(lst); \41 (ap).last = (__u8 *) &(lst)42 43 34 /** 44 35 * va_arg macro for MIPS32 - problem is that 64 bit values must be aligned on an 8-byte boundary (32bit values not) 45 36 * To satisfy this, paddings must be sometimes inserted. 46 37 */ 47 #define va_arg(ap, type) \ 48 (*((type *)((ap).last + ((ap).pos += sizeof(type) + ((sizeof(type)==8)&&(((ap).pos)&(4))?4:0)) - sizeof(type)))) 38 39 typedef __address va_list; 40 41 #define va_start(ap, lst) \ 42 ((ap) = (va_list)&(lst) + sizeof(lst)) 43 44 #define va_arg(ap, type) \ 45 (((type *)((ap) = (va_list)( (sizeof(type) <= 4) ? ((__address)((ap) + 2*4 - 1) & (~3)) : ((__address)((ap) + 2*8 -1) & (~7)) )))[-1]) 49 46 50 47 #define va_end(ap) 51 48 52 53 54 49 #endif -
arch/mips32/include/context.h
r41fa6f2 r46579c66 33 33 34 34 /* 35 * Put one item onto the stack to support get_stack_base() .35 * Put one item onto the stack to support get_stack_base() and align it up to 8 bytes boundary. 36 36 */ 37 #define SP_DELTA ( 0+STACK_ITEM_SIZE)37 #define SP_DELTA ((0 + STACK_ITEM_SIZE + 7) & (~7)) 38 38 39 39 -
arch/mips32/include/context_offset.h
r41fa6f2 r46579c66 49 49 #define EOFFSET_STATUS 0x7c 50 50 #define EOFFSET_EPC 0x80 51 #define REGISTER_SPACE 13 251 #define REGISTER_SPACE 136 -
arch/mips32/include/exception.h
r41fa6f2 r46579c66 91 91 __u32 status; /* cp0_status */ 92 92 __u32 epc; /* cp0_epc */ 93 __u32 padding; /* padding to align stack on 8 bytes boundary */ 93 94 }; 94 95 -
test/print/print1/test.c
r41fa6f2 r46579c66 31 31 void test(void) 32 32 { 33 __u64 u64const = 0x0123456789ABCDEFLL;34 33 printf(" Printf test \n"); 35 printf(" Q %Q %q \n",u64const, u64const); 34 printf(" Q %Q %q \n",0x1111111111111111ull, 0x2222222222222222ull); 35 printf(" Q,l %Q %l \n", 0x3333333333333333ull, 0x01234567); 36 printf(" l,Q %l %Q \n", 0x01234567, 0x4444444444444444ull); 36 37 printf(" L %L %l \n",0x01234567 ,0x01234567); 37 38 printf(" W %W %w \n",0x0123 ,0x0123);
Note:
See TracChangeset
for help on using the changeset viewer.