Ignore:
Timestamp:
Jan 21, 2018, 12:10:09 AM (6 years ago)
Author:
coas-nagasima
Message:

prototoolに関連するプロジェクトをnewlibからmuslを使うよう変更・更新
ntshellをnewlibの下位の実装から、muslのsyscallの実装に変更・更新
以下のOSSをアップデート
・mruby-1.3.0
・musl-1.1.18
・onigmo-6.1.3
・tcc-0.9.27
以下のOSSを追加
・openssl-1.1.0e
・curl-7.57.0
・zlib-1.2.11
以下のmrbgemsを追加
・iij/mruby-digest
・iij/mruby-env
・iij/mruby-errno
・iij/mruby-iijson
・iij/mruby-ipaddr
・iij/mruby-mock
・iij/mruby-require
・iij/mruby-tls-openssl

Location:
EcnlProtoTool/trunk/tcc-0.9.27
Files:
1 edited
1 moved

Legend:

Unmodified
Added
Removed
  • EcnlProtoTool/trunk/tcc-0.9.27/include/stdarg.h

    r321 r331  
    55#ifndef _WIN64
    66
    7 typedef void *va_list;
     7//This should be in sync with the declaration on our lib/libtcc1.c
     8/* GCC compatible definition of va_list. */
     9typedef struct {
     10    unsigned int gp_offset;
     11    unsigned int fp_offset;
     12    union {
     13        unsigned int overflow_offset;
     14        char *overflow_arg_area;
     15    };
     16    char *reg_save_area;
     17} __va_list_struct;
    818
    9 va_list __va_start(void *fp);
    10 void *__va_arg(va_list ap, int arg_type, int size);
    11 va_list __va_copy(va_list src);
    12 void __va_end(va_list ap);
     19typedef __va_list_struct va_list[1];
    1320
    14 #define va_start(ap, last) ((ap) = __va_start(__builtin_frame_address(0)))
     21void __va_start(__va_list_struct *ap, void *fp);
     22void *__va_arg(__va_list_struct *ap, int arg_type, int size, int align);
     23
     24#define va_start(ap, last) __va_start(ap, __builtin_frame_address(0))
    1525#define va_arg(ap, type)                                                \
    16     (*(type *)(__va_arg(ap, __builtin_va_arg_types(type), sizeof(type))))
    17 #define va_copy(dest, src) ((dest) = __va_copy(src))
    18 #define va_end(ap) __va_end(ap)
     26    (*(type *)(__va_arg(ap, __builtin_va_arg_types(type), sizeof(type), __alignof__(type))))
     27#define va_copy(dest, src) (*(dest) = *(src))
     28#define va_end(ap)
     29
     30/* avoid conflicting definition for va_list on Macs. */
     31#define _VA_LIST_T
    1932
    2033#else /* _WIN64 */
    2134typedef char *va_list;
    22 #define va_start(ap,last) ap = ((char *)&(last)) + ((sizeof(last)+7)&~7)
    23 #define va_arg(ap,type) (ap += (sizeof(type)+7)&~7, *(type *)(ap - ((sizeof(type)+7)&~7)))
     35#define va_start(ap,last) __builtin_va_start(ap,last)
     36#define va_arg(ap, t) ((sizeof(t) > 8 || (sizeof(t) & (sizeof(t) - 1))) \
     37        ? **(t **)((ap += 8) - 8) : *(t  *)((ap += 8) - 8))
     38#define va_copy(dest, src) ((dest) = (src))
     39#define va_end(ap)
     40#endif
     41
     42#elif __arm__
     43typedef char *va_list;
     44#define _tcc_alignof(type) ((int)&((struct {char c;type x;} *)0)->x)
     45#define _tcc_align(addr,type) (((unsigned)addr + _tcc_alignof(type) - 1) \
     46                               & ~(_tcc_alignof(type) - 1))
     47#define va_start(ap,last) ap = ((char *)&(last)) + ((sizeof(last)+3)&~3)
     48#define va_arg(ap,type) (ap = (void *) ((_tcc_align(ap,type)+sizeof(type)+3) \
     49                        &~3), *(type *)(ap - ((sizeof(type)+3)&~3)))
    2450#define va_copy(dest, src) (dest) = (src)
    2551#define va_end(ap)
    26 #endif
     52
     53#elif defined(__aarch64__)
     54typedef struct {
     55    void *__stack;
     56    void *__gr_top;
     57    void *__vr_top;
     58    int   __gr_offs;
     59    int   __vr_offs;
     60} va_list;
     61#define va_start(ap, last) __va_start(ap, last)
     62#define va_arg(ap, type) __va_arg(ap, type)
     63#define va_end(ap)
     64#define va_copy(dest, src) ((dest) = (src))
    2765
    2866#else /* __i386__ */
Note: See TracChangeset for help on using the changeset viewer.