This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/14282] New: ICE in sh-elf-gcc with -m4-single-only and -O2
- From: "gcc-bugzilla at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 25 Feb 2004 01:07:01 -0000
- Subject: [Bug c/14282] New: ICE in sh-elf-gcc with -m4-single-only and -O2
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
Latest sh-elf-gcc gets ICE compiling newlib. I believe problem is
due to a recent check in during the last few days.
Environment:
System: Linux fred.ninemoons.com 2.4.22-1.2174.nptl #1 Wed Feb 18 16:38:32 EST 2004 i686 athlon i386 GNU/Linux
Architecture: i686
host: i686-pc-linux-gnu
build: i686-pc-linux-gnu
target: sh-unknown-elf
configured with: /src/sourceware/gcc/gcc/configure -v --prefix=/usr/local/sourceware --with-newlib --with-gnu-as --with-gnu-ld --target=sh-elf --enable-languages=c,c++
How-To-Repeat:
$ sh-elf-gcc -m4-single-only -O2 -c vfprintf.i
/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c: In function `_vfprintf_r':
/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c:1202: error: unable to find a register to spill in class `R0_REGS'
/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c:1202: error: this is the insn:
(insn:HI 1207 1202 1203 126 /src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c:1269 (set (reg:SI 147 t)
(eq:SI (reg/v:SI 163 [ ch ])
(const_int 103 [0x67]))) 1 {cmpeqsi_t} (insn_list:REG_DEP_OUTPUT 1202 (nil))
(nil))
/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c:1202: internal compiler error: in spill_failure, at reload1.c:1873
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
vfprintf.i is included below.
# 1 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
# 1 "/links1/build/sourceware/newlib/T-sh-elf/sh-elf/m4-single-only/newlib/libc/stdio//"
# 1 "<built-in>"
# 1 "<command line>"
# 1 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
# 182 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
# 1 "/src/sourceware/newlib/src/newlib/libc/include/_ansi.h" 1 3 4
# 15 "/src/sourceware/newlib/src/newlib/libc/include/_ansi.h" 3 4
# 1 "/build/sourceware/newlib/T-sh-elf/sh-elf/m4-single-only/newlib/targ-include/newlib.h" 1 3 4
# 16 "/src/sourceware/newlib/src/newlib/libc/include/_ansi.h" 2 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/sys/config.h" 1 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/machine/ieeefp.h" 1 3 4
# 5 "/src/sourceware/newlib/src/newlib/libc/include/sys/config.h" 2 3 4
# 17 "/src/sourceware/newlib/src/newlib/libc/include/_ansi.h" 2 3 4
# 183 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 1 3 4
# 29 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/_ansi.h" 1 3 4
# 30 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 2 3 4
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 1 3 4
# 213 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 3 4
typedef unsigned int size_t;
# 35 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 2 3 4
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stdarg.h" 1 3 4
# 43 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stdarg.h" 3 4
typedef __builtin_va_list __gnuc_va_list;
# 38 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 2 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 1 3 4
# 14 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/sys/_types.h" 1 3 4
# 12 "/src/sourceware/newlib/src/newlib/libc/include/sys/_types.h" 3 4
typedef long _off_t;
__extension__ typedef long long _off64_t;
typedef int _ssize_t;
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 1 3 4
# 354 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 3 4
typedef unsigned int wint_t;
# 23 "/src/sourceware/newlib/src/newlib/libc/include/sys/_types.h" 2 3 4
typedef struct
{
int __count;
union
{
wint_t __wch;
unsigned char __wchb[4];
} __value;
} _mbstate_t;
typedef int _flock_t;
typedef void *_iconv_t;
# 15 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 2 3 4
typedef unsigned long __ULong;
# 40 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 3 4
struct _Bigint
{
struct _Bigint *_next;
int _k, _maxwds, _sign, _wds;
__ULong _x[1];
};
struct __tm
{
int __tm_sec;
int __tm_min;
int __tm_hour;
int __tm_mday;
int __tm_mon;
int __tm_year;
int __tm_wday;
int __tm_yday;
int __tm_isdst;
};
struct _on_exit_args {
void * _fnargs[32];
__ULong _fntypes;
};
# 80 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 3 4
struct _atexit {
struct _atexit *_next;
int _ind;
void (*_fns[32])(void);
struct _on_exit_args _on_exit_args;
};
# 95 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 3 4
struct __sbuf {
unsigned char *_base;
int _size;
};
typedef long _fpos_t;
# 160 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 3 4
struct __sFILE {
unsigned char *_p;
int _r;
int _w;
short _flags;
short _file;
struct __sbuf _bf;
int _lbfsize;
void * _cookie;
int (*_read) (void * _cookie, char *_buf, int _n);
int (*_write) (void * _cookie, const char *_buf, int _n);
_fpos_t (*_seek) (void * _cookie, _fpos_t _offset, int _whence);
int (*_close) (void * _cookie);
struct __sbuf _ub;
unsigned char *_up;
int _ur;
unsigned char _ubuf[3];
unsigned char _nbuf[1];
struct __sbuf _lb;
int _blksize;
int _offset;
struct _reent *_data;
_flock_t _lock;
};
# 253 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 3 4
typedef struct __sFILE __FILE;
struct _glue
{
struct _glue *_next;
int _niobs;
__FILE *_iobs;
};
# 284 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 3 4
struct _rand48 {
unsigned short _seed[3];
unsigned short _mult[3];
unsigned short _add;
};
# 533 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 3 4
struct _reent
{
int _errno;
__FILE *_stdin, *_stdout, *_stderr;
int _inc;
char _emergency[25];
int _current_category;
const char *_current_locale;
int __sdidinit;
void (*__cleanup) (struct _reent *);
struct _Bigint *_result;
int _result_k;
struct _Bigint *_p5s;
struct _Bigint **_freelist;
int _cvtlen;
char *_cvtbuf;
union
{
struct
{
unsigned int _unused_rand;
char * _strtok_last;
char _asctime_buf[26];
struct __tm _localtime_buf;
int _gamma_signgam;
__extension__ unsigned long long _rand_next;
struct _rand48 _r48;
_mbstate_t _mblen_state;
_mbstate_t _mbtowc_state;
_mbstate_t _wctomb_state;
char _l64a_buf[8];
char _signal_buf[24];
int _getdate_err;
_mbstate_t _mbrlen_state;
_mbstate_t _mbrtowc_state;
_mbstate_t _mbsrtowcs_state;
_mbstate_t _wcrtomb_state;
_mbstate_t _wcsrtombs_state;
} _reent;
struct
{
unsigned char * _nextf[30];
unsigned int _nmalloc[30];
} _unused;
} _new;
struct _atexit *_atexit;
struct _atexit _atexit0;
void (**(_sig_func))(int);
struct _glue __sglue;
__FILE __sf[3];
};
# 730 "/src/sourceware/newlib/src/newlib/libc/include/sys/reent.h" 3 4
extern struct _reent *_impure_ptr ;
void _reclaim_reent (struct _reent *);
# 46 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 2 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/sys/types.h" 1 3 4
# 24 "/src/sourceware/newlib/src/newlib/libc/include/sys/types.h" 3 4
typedef short int __int16_t;
typedef unsigned short int __uint16_t;
typedef int __int32_t;
typedef unsigned int __uint32_t;
__extension__ typedef long long __int64_t;
__extension__ typedef unsigned long long __uint64_t;
# 55 "/src/sourceware/newlib/src/newlib/libc/include/sys/types.h" 3 4
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 1 3 4
# 151 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 3 4
typedef int ptrdiff_t;
# 325 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 3 4
typedef long int wchar_t;
# 56 "/src/sourceware/newlib/src/newlib/libc/include/sys/types.h" 2 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/machine/types.h" 1 3 4
# 36 "/src/sourceware/newlib/src/newlib/libc/include/machine/types.h" 3 4
typedef long int __off_t;
typedef int __pid_t;
__extension__ typedef long long int __loff_t;
# 57 "/src/sourceware/newlib/src/newlib/libc/include/sys/types.h" 2 3 4
# 78 "/src/sourceware/newlib/src/newlib/libc/include/sys/types.h" 3 4
typedef unsigned char u_char;
typedef unsigned short u_short;
typedef unsigned int u_int;
typedef unsigned long u_long;
typedef unsigned short ushort;
typedef unsigned int uint;
typedef unsigned long clock_t;
typedef long time_t;
struct timespec {
time_t tv_sec;
long tv_nsec;
};
struct itimerspec {
struct timespec it_interval;
struct timespec it_value;
};
typedef long daddr_t;
typedef char * caddr_t;
# 121 "/src/sourceware/newlib/src/newlib/libc/include/sys/types.h" 3 4
typedef unsigned short ino_t;
# 155 "/src/sourceware/newlib/src/newlib/libc/include/sys/types.h" 3 4
typedef short dev_t;
typedef long off_t;
typedef unsigned short uid_t;
typedef unsigned short gid_t;
typedef int pid_t;
typedef long key_t;
typedef _ssize_t ssize_t;
# 184 "/src/sourceware/newlib/src/newlib/libc/include/sys/types.h" 3 4
typedef unsigned int mode_t __attribute__ ((__mode__ (__SI__)));
typedef unsigned short nlink_t;
# 211 "/src/sourceware/newlib/src/newlib/libc/include/sys/types.h" 3 4
typedef long fd_mask;
typedef struct _types_fd_set {
fd_mask fds_bits[(((64)+(((sizeof (fd_mask) * 8))-1))/((sizeof (fd_mask) * 8)))];
} _types_fd_set;
# 47 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 2 3 4
typedef __FILE FILE;
# 59 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 3 4
typedef _fpos_t fpos_t;
# 1 "/src/sourceware/newlib/src/newlib/libc/include/sys/stdio.h" 1 3 4
# 66 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 2 3 4
# 170 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 3 4
FILE * tmpfile (void);
char * tmpnam (char *);
int fclose (FILE *);
int fflush (FILE *);
FILE * freopen (const char *, const char *, FILE *);
void setbuf (FILE *, char *);
int setvbuf (FILE *, char *, int, size_t);
int fprintf (FILE *, const char *, ...);
int fscanf (FILE *, const char *, ...);
int printf (const char *, ...);
int scanf (const char *, ...);
int sscanf (const char *, const char *, ...);
int vfprintf (FILE *, const char *, __gnuc_va_list);
int vprintf (const char *, __gnuc_va_list);
int vsprintf (char *, const char *, __gnuc_va_list);
int fgetc (FILE *);
char * fgets (char *, int, FILE *);
int fputc (int, FILE *);
int fputs (const char *, FILE *);
int getc (FILE *);
int getchar (void);
char * gets (char *);
int putc (int, FILE *);
int putchar (int);
int puts (const char *);
int ungetc (int, FILE *);
size_t fread (void *, size_t _size, size_t _n, FILE *);
size_t fwrite (const void * , size_t _size, size_t _n, FILE *);
int fgetpos (FILE *, fpos_t *);
int fseek (FILE *, long, int);
int fsetpos (FILE *, const fpos_t *);
long ftell ( FILE *);
void rewind (FILE *);
void clearerr (FILE *);
int feof (FILE *);
int ferror (FILE *);
void perror (const char *);
FILE * fopen (const char *_name, const char *_type);
int sprintf (char *, const char *, ...);
int remove (const char *);
int rename (const char *, const char *);
int asprintf (char **, const char *, ...);
int fseeko (FILE *, off_t, int);
off_t ftello ( FILE *);
int vfiprintf (FILE *, const char *, __gnuc_va_list);
int iprintf (const char *, ...);
int fiprintf (FILE *, const char *, ...);
int siprintf (char *, const char *, ...);
char * tempnam (const char *, const char *);
int vasprintf (char **, const char *, __gnuc_va_list);
int vsnprintf (char *, size_t, const char *, __gnuc_va_list);
int vfscanf (FILE *, const char *, __gnuc_va_list);
int vscanf (const char *, __gnuc_va_list);
int vsscanf (const char *, const char *, __gnuc_va_list);
int fcloseall (void);
int snprintf (char *, size_t, const char *, ...);
# 252 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 3 4
FILE * fdopen (int, const char *);
int fileno (FILE *);
int getw (FILE *);
int pclose (FILE *);
FILE * popen (const char *, const char *);
int putw (int, FILE *);
void setbuffer (FILE *, char *, int);
int setlinebuf (FILE *);
int getc_unlocked (FILE *);
int getchar_unlocked (void);
void flockfile (FILE *);
int ftrylockfile (FILE *);
void funlockfile (FILE *);
int putc_unlocked (int, FILE *);
int putchar_unlocked (int);
int _asprintf_r (struct _reent *, char **, const char *, ...);
int _fcloseall_r (struct _reent *);
FILE * _fdopen_r (struct _reent *, int, const char *);
FILE * _fopen_r (struct _reent *, const char *, const char *);
int _fscanf_r (struct _reent *, FILE *, const char *, ...);
int _getchar_r (struct _reent *);
char * _gets_r (struct _reent *, char *);
int _iprintf_r (struct _reent *, const char *, ...);
int _mkstemp_r (struct _reent *, char *);
char * _mktemp_r (struct _reent *, char *);
void _perror_r (struct _reent *, const char *);
int _printf_r (struct _reent *, const char *, ...);
int _putchar_r (struct _reent *, int);
int _puts_r (struct _reent *, const char *);
int _remove_r (struct _reent *, const char *);
int _rename_r (struct _reent *, const char *_old, const char *_new);
int _scanf_r (struct _reent *, const char *, ...);
int _sprintf_r (struct _reent *, char *, const char *, ...);
int _snprintf_r (struct _reent *, char *, size_t, const char *, ...);
int _sscanf_r (struct _reent *, const char *, const char *, ...);
char * _tempnam_r (struct _reent *, const char *, const char *);
FILE * _tmpfile_r (struct _reent *);
char * _tmpnam_r (struct _reent *, char *);
int _vasprintf_r (struct _reent *, char **, const char *, __gnuc_va_list);
int _vfprintf_r (struct _reent *, FILE *, const char *, __gnuc_va_list);
int _vprintf_r (struct _reent *, const char *, __gnuc_va_list);
int _vsprintf_r (struct _reent *, char *, const char *, __gnuc_va_list);
int _vsnprintf_r (struct _reent *, char *, size_t, const char *, __gnuc_va_list);
int _vfscanf_r (struct _reent *, FILE *, const char *, __gnuc_va_list);
int _vscanf_r (struct _reent *, const char *, __gnuc_va_list);
int _vsscanf_r (struct _reent *, const char *, const char *, __gnuc_va_list);
ssize_t __getdelim (char **, size_t *, int, FILE *);
ssize_t __getline (char **, size_t *, FILE *);
# 334 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 3 4
int __srget (FILE *);
int __swbuf (int, FILE *);
FILE *funopen (const void * _cookie, int (*readfn)(void * _cookie, char *_buf, int _n), int (*writefn)(void * _cookie, const char *_buf, int _n), fpos_t (*seekfn)(void * _cookie, fpos_t _off, int _whence), int (*closefn)(void * _cookie));
# 441 "/src/sourceware/newlib/src/newlib/libc/include/stdio.h" 3 4
# 184 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/include/stdlib.h" 1 3 4
# 14 "/src/sourceware/newlib/src/newlib/libc/include/stdlib.h" 3 4
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 1 3 4
# 15 "/src/sourceware/newlib/src/newlib/libc/include/stdlib.h" 2 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/machine/stdlib.h" 1 3 4
# 18 "/src/sourceware/newlib/src/newlib/libc/include/stdlib.h" 2 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/alloca.h" 1 3 4
# 20 "/src/sourceware/newlib/src/newlib/libc/include/stdlib.h" 2 3 4
typedef struct
{
int quot;
int rem;
} div_t;
typedef struct
{
long quot;
long rem;
} ldiv_t;
typedef struct
{
long long int quot;
long long int rem;
} lldiv_t;
# 53 "/src/sourceware/newlib/src/newlib/libc/include/stdlib.h" 3 4
extern int __mb_cur_max;
void abort (void) __attribute__ ((noreturn));
int abs (int);
int atexit (void (*__func)(void));
double atof (const char *__nptr);
float atoff (const char *__nptr);
int atoi (const char *__nptr);
int _atoi_r (struct _reent *, const char *__nptr);
long atol (const char *__nptr);
long _atol_r (struct _reent *, const char *__nptr);
void * bsearch (const void * __key, const void * __base, size_t __nmemb, size_t __size, int (* _compar) (const void *, const void *));
void * calloc (size_t __nmemb, size_t __size);
div_t div (int __numer, int __denom);
void exit (int __status) __attribute__ ((noreturn));
void free (void *);
char * getenv (const char *__string);
char * _getenv_r (struct _reent *, const char *__string);
char * _findenv (const char *, int *);
char * _findenv_r (struct _reent *, const char *, int *);
long labs (long);
ldiv_t ldiv (long __numer, long __denom);
void * malloc (size_t __size);
int mblen (const char *, size_t);
int _mblen_r (struct _reent *, const char *, size_t, _mbstate_t *);
int mbtowc (wchar_t *, const char *, size_t);
int _mbtowc_r (struct _reent *, wchar_t *, const char *, size_t, _mbstate_t *);
int wctomb (char *, wchar_t);
int _wctomb_r (struct _reent *, char *, wchar_t, _mbstate_t *);
size_t mbstowcs (wchar_t *, const char *, size_t);
size_t _mbstowcs_r (struct _reent *, wchar_t *, const char *, size_t, _mbstate_t *);
size_t wcstombs (char *, const wchar_t *, size_t);
size_t _wcstombs_r (struct _reent *, char *, const wchar_t *, size_t, _mbstate_t *);
int mkstemp (char *);
char * mktemp (char *);
void qsort (void * __base, size_t __nmemb, size_t __size, int(*_compar)(const void *, const void *));
int rand (void);
void * realloc (void * __r, size_t __size);
void srand (unsigned __seed);
double strtod (const char *__n, char **__end_PTR);
double _strtod_r (struct _reent *,const char *__n, char **__end_PTR);
float strtof (const char *__n, char **__end_PTR);
long strtol (const char *__n, char **__end_PTR, int __base);
long _strtol_r (struct _reent *,const char *__n, char **__end_PTR, int __base);
unsigned long strtoul (const char *__n, char **__end_PTR, int __base);
unsigned long _strtoul_r (struct _reent *,const char *__n, char **__end_PTR, int __base);
int system (const char *__string);
long a64l (const char *__input);
char * l64a (long __input);
char * _l64a_r (struct _reent *,long __input);
int on_exit (void (*__func)(int, void *),void * __arg);
void _Exit (int __status) __attribute__ ((noreturn));
int putenv (const char *__string);
int _putenv_r (struct _reent *, const char *__string);
int setenv (const char *__string, const char *__value, int __overwrite);
int _setenv_r (struct _reent *, const char *__string, const char *__value, int __overwrite);
char * gcvt (double,int,char *);
char * gcvtf (float,int,char *);
char * fcvt (double,int,int *,int *);
char * fcvtf (float,int,int *,int *);
char * ecvt (double,int,int *,int *);
char * ecvtbuf (double, int, int*, int*, char *);
char * fcvtbuf (double, int, int*, int*, char *);
char * ecvtf (float,int,int *,int *);
char * dtoa (double, int, int, int *, int*, char**);
int rand_r (unsigned *__seed);
double drand48 (void);
double _drand48_r (struct _reent *);
double erand48 (unsigned short [3]);
double _erand48_r (struct _reent *, unsigned short [3]);
long jrand48 (unsigned short [3]);
long _jrand48_r (struct _reent *, unsigned short [3]);
void lcong48 (unsigned short [7]);
void _lcong48_r (struct _reent *, unsigned short [7]);
long lrand48 (void);
long _lrand48_r (struct _reent *);
long mrand48 (void);
long _mrand48_r (struct _reent *);
long nrand48 (unsigned short [3]);
long _nrand48_r (struct _reent *, unsigned short [3]);
unsigned short *
seed48 (unsigned short [3]);
unsigned short *
_seed48_r (struct _reent *, unsigned short [3]);
void srand48 (long);
void _srand48_r (struct _reent *, long);
long long atoll (const char *__nptr);
long long _atoll_r (struct _reent *, const char *__nptr);
long long llabs (long long);
lldiv_t lldiv (long long __numer, long long __denom);
long long strtoll (const char *__n, char **__end_PTR, int __base);
long long _strtoll_r (struct _reent *, const char *__n, char **__end_PTR, int __base);
unsigned long long strtoull (const char *__n, char **__end_PTR, int __base);
unsigned long long _strtoull_r (struct _reent *, const char *__n, char **__end_PTR, int __base);
void cfree (void *);
# 192 "/src/sourceware/newlib/src/newlib/libc/include/stdlib.h" 3 4
char * _dtoa_r (struct _reent *, double, int, int, int *, int*, char**);
void * _malloc_r (struct _reent *, size_t);
void * _calloc_r (struct _reent *, size_t, size_t);
void _free_r (struct _reent *, void *);
void * _realloc_r (struct _reent *, void *, size_t);
void _mstats_r (struct _reent *, char *);
int _system_r (struct _reent *, const char *);
void __eprintf (const char *, const char *, unsigned int, const char *);
# 233 "/src/sourceware/newlib/src/newlib/libc/include/stdlib.h" 3 4
# 185 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/include/string.h" 1 3 4
# 14 "/src/sourceware/newlib/src/newlib/libc/include/string.h" 3 4
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 1 3 4
# 15 "/src/sourceware/newlib/src/newlib/libc/include/string.h" 2 3 4
void * memchr (const void *, int, size_t);
int memcmp (const void *, const void *, size_t);
void * memcpy (void *, const void *, size_t);
void * memmove (void *, const void *, size_t);
void * memset (void *, int, size_t);
char *strcat (char *, const char *);
char *strchr (const char *, int);
int strcmp (const char *, const char *);
int strcoll (const char *, const char *);
char *strcpy (char *, const char *);
size_t strcspn (const char *, const char *);
char *strerror (int);
size_t strlen (const char *);
char *strncat (char *, const char *, size_t);
int strncmp (const char *, const char *, size_t);
char *strncpy (char *, const char *, size_t);
char *strpbrk (const char *, const char *);
char *strrchr (const char *, int);
size_t strspn (const char *, const char *);
char *strstr (const char *, const char *);
char *strtok (char *, const char *);
size_t strxfrm (char *, const char *, size_t);
char *strtok_r (char *, const char *, char **);
int bcmp (const void *, const void *, size_t);
void bcopy (const void *, void *, size_t);
void bzero (void *, size_t);
int ffs (int);
char *index (const char *, int);
void * memccpy (void *, const void *, int, size_t);
void * mempcpy (void *, const void *, size_t);
char *rindex (const char *, int);
int strcasecmp (const char *, const char *);
char *strdup (const char *);
char *_strdup_r (struct _reent *, const char *);
char *strndup (const char *, size_t);
char *_strndup_r (struct _reent *, const char *, size_t);
char *strerror_r (int, char *, size_t);
size_t strlcat (char *, const char *, size_t);
size_t strlcpy (char *, const char *, size_t);
int strncasecmp (const char *, const char *, size_t);
size_t strnlen (const char *, size_t);
char *strsep (char **, const char *);
char *strlwr (char *);
char *strupr (char *);
# 98 "/src/sourceware/newlib/src/newlib/libc/include/string.h" 3 4
# 186 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/include/limits.h" 1 3 4
# 125 "/src/sourceware/newlib/src/newlib/libc/include/limits.h" 3 4
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/limits.h" 1 3 4
# 126 "/src/sourceware/newlib/src/newlib/libc/include/limits.h" 2 3 4
# 187 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/include/reent.h" 1 3 4
# 54 "/src/sourceware/newlib/src/newlib/libc/include/reent.h" 3 4
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 1 3 4
# 55 "/src/sourceware/newlib/src/newlib/libc/include/reent.h" 2 3 4
struct stat;
struct tms;
struct timeval;
struct timezone;
extern int _close_r (struct _reent *, int);
extern int _execve_r (struct _reent *, char *, char **, char **);
extern int _fcntl_r (struct _reent *, int, int, int);
extern int _fork_r (struct _reent *);
extern int _fstat_r (struct _reent *, int, struct stat *);
extern int _getpid_r (struct _reent *);
extern int _kill_r (struct _reent *, int, int);
extern int _link_r (struct _reent *, const char *, const char *);
extern _off_t _lseek_r (struct _reent *, int, _off_t, int);
extern int _open_r (struct _reent *, const char *, int, int);
extern _ssize_t _read_r (struct _reent *, int, void *, size_t);
extern void *_sbrk_r (struct _reent *, ptrdiff_t);
extern int _stat_r (struct _reent *, const char *, struct stat *);
extern unsigned long _times_r (struct _reent *, struct tms *);
extern int _unlink_r (struct _reent *, const char *);
extern int _wait_r (struct _reent *, int *);
extern _ssize_t _write_r (struct _reent *, int, const void *, size_t);
extern int _gettimeofday_r (struct _reent *, struct timeval *tp, struct timezone *tzp);
# 188 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/include/wchar.h" 1 3 4
# 11 "/src/sourceware/newlib/src/newlib/libc/include/wchar.h" 3 4
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 1 3 4
# 12 "/src/sourceware/newlib/src/newlib/libc/include/wchar.h" 2 3 4
# 36 "/src/sourceware/newlib/src/newlib/libc/include/wchar.h" 3 4
typedef _mbstate_t mbstate_t;
wint_t btowc (int);
int wctob (wint_t);
size_t mbrlen (const char * , size_t, mbstate_t *);
size_t mbrtowc (wchar_t * , const char * , size_t, mbstate_t *);
size_t _mbrtowc_r (struct _reent *, wchar_t * , const char * , size_t, mbstate_t *);
int mbsinit (const mbstate_t *);
size_t mbsrtowcs (wchar_t * , const char ** , size_t, mbstate_t *);
size_t wcrtomb (char * , wchar_t, mbstate_t *);
size_t _wcrtomb_r (struct _reent *, char * , wchar_t, mbstate_t *);
size_t wcsrtombs (char * , const wchar_t ** , size_t, mbstate_t *);
size_t _wcsrtombs_r (struct _reent *, char * , const wchar_t ** , size_t, mbstate_t *);
wchar_t *wcscat (wchar_t * , const wchar_t *);
wchar_t *wcschr (const wchar_t *, wchar_t);
int wcscmp (const wchar_t *, const wchar_t *);
int wcscoll (const wchar_t *, const wchar_t *);
wchar_t *wcscpy (wchar_t * , const wchar_t *);
size_t wcscspn (const wchar_t *, const wchar_t *);
size_t wcslcat (wchar_t *, const wchar_t *, size_t);
size_t wcslcpy (wchar_t *, const wchar_t *, size_t);
size_t wcslen (const wchar_t *);
wchar_t *wcsncat (wchar_t * , const wchar_t * , size_t);
int wcsncmp (const wchar_t *, const wchar_t *, size_t);
wchar_t *wcsncpy (wchar_t * , const wchar_t * , size_t);
size_t wcsnlen (const wchar_t *, size_t);
wchar_t *wcspbrk (const wchar_t *, const wchar_t *);
wchar_t *wcsrchr (const wchar_t *, wchar_t);
size_t wcsspn (const wchar_t *, const wchar_t *);
wchar_t *wcsstr (const wchar_t *, const wchar_t *);
int wcswidth (const wchar_t *, size_t);
int wcwidth (const wchar_t);
wchar_t *wmemchr (const wchar_t *, wchar_t, size_t);
int wmemcmp (const wchar_t *, const wchar_t *, size_t);
wchar_t *wmemcpy (wchar_t * , const wchar_t * , size_t);
wchar_t *wmemmove (wchar_t *, const wchar_t *, size_t);
wchar_t *wmemset (wchar_t *, wchar_t, size_t);
# 189 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/include/sys/lock.h" 1 3 4
typedef int _LOCK_T;
typedef int _LOCK_RECURSIVE_T;
# 191 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stdarg.h" 1 3 4
# 105 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stdarg.h" 3 4
typedef __gnuc_va_list va_list;
# 194 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/stdio/local.h" 1
# 28 "/src/sourceware/newlib/src/newlib/libc/stdio/local.h"
# 1 "/src/sourceware/newlib/src/newlib/libc/include/unistd.h" 1 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/sys/unistd.h" 1 3 4
# 13 "/src/sourceware/newlib/src/newlib/libc/include/sys/unistd.h" 3 4
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/stddef.h" 1 3 4
# 14 "/src/sourceware/newlib/src/newlib/libc/include/sys/unistd.h" 2 3 4
extern char **environ;
void _exit (int __status ) __attribute__ ((noreturn));
int access (const char *__path, int __amode );
unsigned alarm (unsigned __secs );
int chdir (const char *__path );
int chmod (const char *__path, mode_t __mode );
int chown (const char *__path, uid_t __owner, gid_t __group );
int close (int __fildes );
char *ctermid (char *__s );
char *cuserid (char *__s );
int dup (int __fildes );
int dup2 (int __fildes, int __fildes2 );
int execl (const char *__path, const char *, ... );
int execle (const char *__path, const char *, ... );
int execlp (const char *__file, const char *, ... );
int execv (const char *__path, char * const __argv[] );
int execve (const char *__path, char * const __argv[], char * const __envp[] );
int execvp (const char *__file, char * const __argv[] );
int fchmod (int __fildes, mode_t __mode );
int fchown (int __fildes, uid_t __owner, gid_t __group );
pid_t fork (void );
long fpathconf (int __fd, int __name );
int fsync (int __fd);
int fdatasync (int __fd);
char *getcwd (char *__buf, size_t __size );
gid_t getegid (void );
uid_t geteuid (void );
gid_t getgid (void );
int getgroups (int __gidsetsize, gid_t __grouplist[] );
char *getlogin (void );
char *getpass (__const char *__prompt);
size_t getpagesize (void);
pid_t getpgid (pid_t);
pid_t getpgrp (void );
pid_t getpid (void );
pid_t getppid (void );
uid_t getuid (void );
int isatty (int __fildes );
int lchown (const char *__path, uid_t __owner, gid_t __group );
int link (const char *__path1, const char *__path2 );
int nice (int __nice_value );
off_t lseek (int __fildes, off_t __offset, int __whence );
long pathconf (const char *__path, int __name );
int pause (void );
int pipe (int __fildes[2] );
ssize_t pread (int __fd, void *__buf, size_t __nbytes, off_t __offset);
ssize_t pwrite (int __fd, const void *__buf, size_t __nbytes, off_t __offset);
int read (int __fd, void *__buf, size_t __nbyte );
int rmdir (const char *__path );
void * sbrk (ptrdiff_t __incr);
int setgid (gid_t __gid );
int setpgid (pid_t __pid, pid_t __pgid );
int setpgrp (void );
pid_t setsid (void );
int setuid (uid_t __uid );
unsigned sleep (unsigned int __seconds );
void swab (const void *, void *, ssize_t);
long sysconf (int __name );
pid_t tcgetpgrp (int __fildes );
int tcsetpgrp (int __fildes, pid_t __pgrp_id );
char *ttyname (int __fildes );
int unlink (const char *__path );
int vhangup (void );
int write (int __fd, const void *__buf, size_t __nbyte );
extern char *optarg;
extern int optind, opterr, optopt;
int getopt(int, char * const [], const char *);
extern int optreset;
pid_t vfork (void );
extern char *suboptarg;
int getsubopt(char **, char * const *, char **);
# 191 "/src/sourceware/newlib/src/newlib/libc/include/sys/unistd.h" 3 4
int ftruncate (int __fd, off_t __length);
int truncate (const char *, off_t __length);
# 219 "/src/sourceware/newlib/src/newlib/libc/include/sys/unistd.h" 3 4
# 1 "/src/sourceware/newlib/src/newlib/libc/include/sys/features.h" 1 3 4
# 220 "/src/sourceware/newlib/src/newlib/libc/include/sys/unistd.h" 2 3 4
# 5 "/src/sourceware/newlib/src/newlib/libc/include/unistd.h" 2 3 4
# 29 "/src/sourceware/newlib/src/newlib/libc/stdio/local.h" 2
extern int __svfscanf_r (struct _reent *,FILE *, const char *,va_list);
extern FILE *__sfp (struct _reent *);
extern int __sflags (struct _reent *,const char*, int*);
extern int __srefill (FILE *);
extern int __sread (void *, char *, int);
extern int __swrite (void *, char const *, int);
extern _fpos_t __sseek (void *, _fpos_t, int);
extern int __sclose (void *);
extern int __stextmode (int);
extern void __sinit (struct _reent *);
extern void _cleanup_r (struct _reent *);
extern void __smakebuf (FILE *);
extern int _fwalk (struct _reent *, int (*)(FILE *));
struct _glue * __sfmoreglue (struct _reent *,int n);
extern int __srefill (FILE *fp);
# 79 "/src/sourceware/newlib/src/newlib/libc/stdio/local.h"
char *_dcvt (struct _reent *, char *, double, int, int, char, int);
char *_sicvt (char *, short, char);
char *_icvt (char *, int, char);
char *_licvt (char *, long, char);
char *_llicvt (char *, long long, char);
# 199 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/stdio/fvwrite.h" 1
# 24 "/src/sourceware/newlib/src/newlib/libc/stdio/fvwrite.h"
struct __siov {
const void * iov_base;
size_t iov_len;
};
struct __suio {
struct __siov *uio_iov;
int uio_iovcnt;
int uio_resid;
};
extern int __sfvwrite (FILE *, struct __suio *);
extern int __swsetup (FILE *);
# 200 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/stdio/vfieeefp.h" 1
# 32 "/src/sourceware/newlib/src/newlib/libc/stdio/vfieeefp.h"
# 1 "/src/sourceware/newlib/src/newlib/libc/include/ieeefp.h" 1 3 4
# 16 "/src/sourceware/newlib/src/newlib/libc/include/ieeefp.h" 3 4
typedef union
{
double value;
struct
{
unsigned int sign : 1;
unsigned int exponent: 11;
unsigned int fraction0:4;
unsigned int fraction1:16;
unsigned int fraction2:16;
unsigned int fraction3:16;
} number;
struct
{
unsigned int sign : 1;
unsigned int exponent: 11;
unsigned int quiet:1;
unsigned int function0:3;
unsigned int function1:16;
unsigned int function2:16;
unsigned int function3:16;
} nan;
struct
{
unsigned long msw;
unsigned long lsw;
} parts;
long aslong[2];
} __ieee_double_shape_type;
# 97 "/src/sourceware/newlib/src/newlib/libc/include/ieeefp.h" 3 4
typedef union
{
float value;
struct
{
unsigned int sign : 1;
unsigned int exponent: 8;
unsigned int fraction0: 7;
unsigned int fraction1: 16;
} number;
struct
{
unsigned int sign:1;
unsigned int exponent:8;
unsigned int quiet:1;
unsigned int function0:6;
unsigned int function1:16;
} nan;
long p1;
} __ieee_float_shape_type;
# 153 "/src/sourceware/newlib/src/newlib/libc/include/ieeefp.h" 3 4
typedef int fp_rnd;
fp_rnd fpgetround (void);
fp_rnd fpsetround (fp_rnd);
typedef int fp_except;
fp_except fpgetmask (void);
fp_except fpsetmask (fp_except);
fp_except fpgetsticky (void);
fp_except fpsetsticky (fp_except);
typedef int fp_rdi;
fp_rdi fpgetroundtoi (void);
fp_rdi fpsetroundtoi (fp_rdi);
int isnan (double);
int isinf (double);
int finite (double);
int isnanf (float);
int isinff (float);
int finitef (float);
# 33 "/src/sourceware/newlib/src/newlib/libc/stdio/vfieeefp.h" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 1 3 4
# 10 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 3 4
union __dmath
{
__ULong i[2];
double d;
};
extern const union __dmath __infinity[];
# 35 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 3 4
extern double atan (double);
extern double cos (double);
extern double sin (double);
extern double tan (double);
extern double tanh (double);
extern double frexp (double, int *);
extern double modf (double, double *);
extern double ceil (double);
extern double fabs (double);
extern double floor (double);
extern double acos (double);
extern double asin (double);
extern double atan2 (double, double);
extern double cosh (double);
extern double sinh (double);
extern double exp (double);
extern double ldexp (double, int);
extern double log (double);
extern double log10 (double);
extern double pow (double, double);
extern double sqrt (double);
extern double fmod (double, double);
# 72 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 3 4
typedef float float_t;
typedef double double_t;
# 82 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 3 4
extern int __fpclassifyf (float x);
extern int __fpclassifyd (double x);
extern int __signbitf (float x);
extern int __signbitd (double x);
# 123 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 3 4
extern double infinity (void);
extern double nan (const char *);
extern int isnan (double);
extern int isinf (double);
extern int finite (double);
extern double copysign (double, double);
extern int ilogb (double);
extern double asinh (double);
extern double cbrt (double);
extern double nextafter (double, double);
extern double rint (double);
extern double scalbn (double, int);
extern double exp2 (double);
extern double scalbln (double, long int);
extern double tgamma (double);
extern double nearbyint (double);
extern long int lrint (double);
extern double round (double);
extern long int lround (double);
extern double trunc (double);
extern double remquo (double, double, int *);
extern double copysign (double, double);
extern double fdim (double, double);
extern double fmax (double, double);
extern double fmin (double, double);
extern double fma (double, double, double);
extern void sincos (double, double *, double *);
extern double log1p (double);
extern double expm1 (double);
extern double acosh (double);
extern double atanh (double);
extern double remainder (double, double);
extern double gamma (double);
extern double gamma_r (double, int *);
extern double lgamma (double);
extern double lgamma_r (double, int *);
extern double erf (double);
extern double erfc (double);
extern double y0 (double);
extern double y1 (double);
extern double yn (int, double);
extern double j0 (double);
extern double j1 (double);
extern double jn (int, double);
extern double hypot (double, double);
extern double cabs();
extern double drem (double, double);
# 191 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 3 4
extern float atanf (float);
extern float cosf (float);
extern float sinf (float);
extern float tanf (float);
extern float tanhf (float);
extern float frexpf (float, int *);
extern float modff (float, float *);
extern float ceilf (float);
extern float fabsf (float);
extern float floorf (float);
extern float acosf (float);
extern float asinf (float);
extern float atan2f (float, float);
extern float coshf (float);
extern float sinhf (float);
extern float expf (float);
extern float ldexpf (float, int);
extern float logf (float);
extern float log10f (float);
extern float powf (float, float);
extern float sqrtf (float);
extern float fmodf (float, float);
# 223 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 3 4
extern float exp2f (float);
extern float scalblnf (float, long int);
extern float tgammaf (float);
extern float nearbyintf (float);
extern long int lrintf (float);
extern float roundf (float);
extern long int lroundf (float);
extern float truncf (float);
extern float remquof (float, float, int *);
extern float copysignf (float, float);
extern float fdimf (float, float);
extern float fmaxf (float, float);
extern float fminf (float, float);
extern float fmaf (float, float, float);
extern float infinityf (void);
extern float nanf (const char *);
extern int isnanf (float);
extern int isinff (float);
extern int finitef (float);
extern float copysignf (float, float);
extern int ilogbf (float);
extern float asinhf (float);
extern float cbrtf (float);
extern float nextafterf (float, float);
extern float rintf (float);
extern float scalbnf (float, int);
extern float log1pf (float);
extern float expm1f (float);
extern void sincosf (float, float *, float *);
extern float acoshf (float);
extern float atanhf (float);
extern float remainderf (float, float);
extern float gammaf (float);
extern float gammaf_r (float, int *);
extern float lgammaf (float);
extern float lgammaf_r (float, int *);
extern float erff (float);
extern float erfcf (float);
extern float y0f (float);
extern float y1f (float);
extern float ynf (int, float);
extern float j0f (float);
extern float j1f (float);
extern float jnf (int, float);
extern float hypotf (float, float);
extern float cabsf();
extern float dremf (float, float);
extern int *__signgam (void);
# 292 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 3 4
struct exception
{
int type;
char *name;
double arg1;
double arg2;
double retval;
int err;
};
extern int matherr (struct exception *e);
# 347 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 3 4
enum __fdlibm_version
{
__fdlibm_ieee = -1,
__fdlibm_svid,
__fdlibm_xopen,
__fdlibm_posix
};
extern const enum __fdlibm_version __fdlib_version;
# 367 "/src/sourceware/newlib/src/newlib/libc/include/math.h" 3 4
# 34 "/src/sourceware/newlib/src/newlib/libc/stdio/vfieeefp.h" 2
# 1 "/links1/usr/local/sourceware/bin/../lib/gcc/sh-elf/3.5.0/include/float.h" 1 3 4
# 35 "/src/sourceware/newlib/src/newlib/libc/stdio/vfieeefp.h" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/include/errno.h" 1 3 4
typedef int error_t;
# 1 "/src/sourceware/newlib/src/newlib/libc/include/sys/errno.h" 1 3 4
# 15 "/src/sourceware/newlib/src/newlib/libc/include/sys/errno.h" 3 4
extern int *__errno (void);
extern const char * const _sys_errlist[];
extern int _sys_nerr;
# 10 "/src/sourceware/newlib/src/newlib/libc/include/errno.h" 2 3 4
# 36 "/src/sourceware/newlib/src/newlib/libc/stdio/vfieeefp.h" 2
# 143 "/src/sourceware/newlib/src/newlib/libc/stdio/vfieeefp.h"
union double_union
{
double d;
__uint32_t i[2];
};
# 201 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 214 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
static int
__sprint(fp, uio)
FILE *fp;
register struct __suio *uio;
{
register int err;
if (uio->uio_resid == 0) {
uio->uio_iovcnt = 0;
return (0);
}
err = __sfvwrite(fp, uio);
uio->uio_resid = 0;
uio->uio_iovcnt = 0;
return (err);
}
static int
__sbprintf(fp, fmt, ap)
register FILE *fp;
const char *fmt;
va_list ap;
{
int ret;
FILE fake;
unsigned char buf[1024];
fake._flags = fp->_flags & ~0x0002;
fake._file = fp->_file;
fake._cookie = fp->_cookie;
fake._write = fp->_write;
fake._bf._base = fake._p = buf;
fake._bf._size = fake._w = sizeof(buf);
fake._lbfsize = 0;
{};
ret = vfprintf(&fake, fmt, ap);
if (ret >= 0 && fflush(&fake))
ret = (-1);
if (fake._flags & 0x0040)
fp->_flags |= 0x0040;
{};
return (ret);
}
# 1 "/src/sourceware/newlib/src/newlib/libc/include/locale.h" 1 3 4
# 24 "/src/sourceware/newlib/src/newlib/libc/include/locale.h" 3 4
struct lconv
{
char *decimal_point;
char *thousands_sep;
char *grouping;
char *int_curr_symbol;
char *currency_symbol;
char *mon_decimal_point;
char *mon_thousands_sep;
char *mon_grouping;
char *positive_sign;
char *negative_sign;
char int_frac_digits;
char frac_digits;
char p_cs_precedes;
char p_sep_by_space;
char n_cs_precedes;
char n_sep_by_space;
char p_sign_posn;
char n_sign_posn;
};
char *setlocale (int category, const char *locale);
struct lconv *localeconv (void);
struct _reent;
char *_setlocale_r (struct _reent *, int category, const char *locale);
struct lconv *_localeconv_r (struct _reent *);
# 276 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 1 "/src/sourceware/newlib/src/newlib/libc/stdio/floatio.h" 1
# 278 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c" 2
# 288 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
static char *cvt (struct _reent *, double, int, int, char *, int *, int, int *);
static int exponent (char *, int, int);
# 310 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
typedef long long * quad_ptr_t;
typedef void * void_ptr_t;
typedef char * char_ptr_t;
typedef long * long_ptr_t;
typedef int * int_ptr_t;
typedef short * short_ptr_t;
# 371 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
int _vfprintf_r (struct _reent *, FILE *, const char *, va_list);
int
vfprintf(FILE * fp , const char *fmt0 , va_list ap)
{
int result;
;
do { if (!_impure_ptr->__sdidinit) __sinit (_impure_ptr); } while (0);
result = _vfprintf_r (_impure_ptr, fp, fmt0, ap);
;
return result;
}
int
_vfprintf_r(struct _reent *data , FILE * fp , const char *fmt0 , va_list ap)
{
register char *fmt;
register int ch;
register int n, m;
register char *cp;
register struct __siov *iovp;
register int flags;
char *fmt_anchor;
int N;
int arg_index;
# 411 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
int ret;
int width;
int prec;
char sign;
char *decimal_point = localeconv()->decimal_point;
char softsign;
union { int i; double d; } _double_ = {0};
int expt;
int expsize = 0;
int ndig;
char expstr[7];
unsigned long long _uquad;
enum { OCT, DEC, HEX } base;
int dprec;
int realsz;
int size;
char *xdigs = ((void *)0);
struct __suio uio;
struct __siov iov[8];
char buf[(308 +39 +1)];
char ox[2];
char *malloc_buf = ((void *)0);
static const char blanks[16] =
{' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' ',' '};
static const char zeroes[16] =
{'0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0'};
# 536 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
if (((((fp)->_flags & 0x0008) == 0 || (fp)->_bf._base == ((void *)0)) && __swsetup(fp)))
return ((-1));
if ((fp->_flags & (0x0002|0x0008|0x0010)) == (0x0002|0x0008) &&
fp->_file >= 0)
return (__sbprintf(fp, fmt0, ap));
fmt = (char *)fmt0;
uio.uio_iov = iovp = iov;
uio.uio_resid = 0;
uio.uio_iovcnt = 0;
ret = 0;
arg_index = 0;
# 560 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
for (;;) {
cp = fmt;
while (*fmt != '\0' && *fmt != '%')
fmt += 1;
if ((m = fmt - cp) != 0) {
{ iovp->iov_base = (cp); iovp->iov_len = (m); uio.uio_resid += (m); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
ret += m;
}
if (*fmt == '\0')
goto done;
fmt_anchor = fmt;
fmt++;
flags = 0;
dprec = 0;
width = 0;
prec = -1;
sign = '\0';
N = arg_index;
rflag: ch = *fmt++;
reswitch: switch (ch) {
case ' ':
if (!sign)
sign = ' ';
goto rflag;
case '#':
flags |= 0x001;
goto rflag;
case '*':
n = N;
# 647 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
width = (__builtin_va_arg(ap,int));
if (width >= 0)
goto rflag;
width = -width;
case '-':
flags |= 0x004;
goto rflag;
case '+':
sign = '+';
goto rflag;
case '.':
if ((ch = *fmt++) == '*') {
n = N;
# 692 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
prec = (__builtin_va_arg(ap,int));
if (prec < 0)
prec = -1;
goto rflag;
}
n = 0;
while (((unsigned)((ch) - '0') <= 9)) {
n = 10 * n + ((ch) - '0');
ch = *fmt++;
}
prec = n < 0 ? -1 : n;
goto reswitch;
case '0':
flags |= 0x080;
goto rflag;
case '1': case '2': case '3': case '4':
case '5': case '6': case '7': case '8': case '9':
n = 0;
do {
n = 10 * n + ((ch) - '0');
ch = *fmt++;
} while (((unsigned)((ch) - '0') <= 9));
# 733 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
width = n;
goto reswitch;
case 'L':
flags |= 0x008;
goto rflag;
case 'h':
flags |= 0x040;
goto rflag;
case 'l':
if (*fmt == 'l') {
fmt++;
flags |= 0x020;
} else {
flags |= 0x010;
}
goto rflag;
case 'q':
flags |= 0x020;
goto rflag;
case 'c':
case 'C':
cp = buf;
if (ch == 'C' || (flags & 0x010)) {
mbstate_t ps;
memset((void *)&ps, '\0', sizeof(mbstate_t));
if ((size = (int)_wcrtomb_r(data, cp,
(wchar_t)(__builtin_va_arg(ap,wint_t)),
&ps)) == -1)
goto error;
}
else {
*cp = (__builtin_va_arg(ap,int));
size = 1;
}
sign = '\0';
break;
case 'D':
flags |= 0x010;
case 'd':
case 'i':
_uquad = (flags&0x020 ? (__builtin_va_arg(ap,long long)) : flags&0x010 ? (__builtin_va_arg(ap,long)) : flags&0x040 ? (long)(short)(__builtin_va_arg(ap,int)) : (long)(__builtin_va_arg(ap,int)));
if ((long long)_uquad < 0)
{
_uquad = -_uquad;
sign = '-';
}
base = DEC;
goto number;
case 'e':
case 'E':
case 'f':
case 'g':
case 'G':
if (prec == -1) {
prec = 6;
} else if ((ch == 'g' || ch == 'G') && prec == 0) {
prec = 1;
}
if (flags & 0x008) {
(_double_.d) = (double) (__builtin_va_arg(ap,long double));
} else {
(_double_.d) = (__builtin_va_arg(ap,double));
}
if (isinf((_double_.d))) {
if ((_double_.d) < 0)
sign = '-';
cp = "Inf";
size = 3;
break;
}
if (isnan((_double_.d))) {
cp = "NaN";
size = 3;
break;
}
# 847 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
flags |= 0x100;
cp = cvt(data, (_double_.d), prec, flags, &softsign,
&expt, ch, &ndig);
if (ch == 'g' || ch == 'G') {
if (expt <= -4 || expt > prec)
ch = (ch == 'g') ? 'e' : 'E';
else
ch = 'g';
}
if (ch <= 'e') {
--expt;
expsize = exponent(expstr, expt, ch);
size = expsize + ndig;
if (ndig > 1 || flags & 0x001)
++size;
} else if (ch == 'f') {
if (expt > 0) {
size = expt;
if (prec || flags & 0x001)
size += prec + 1;
} else
size = (prec || flags & 0x001)
? prec + 2
: 1;
} else if (expt >= ndig) {
size = expt;
if (flags & 0x001)
++size;
} else
size = ndig + (expt > 0 ?
1 : 2 - expt);
if (softsign)
sign = '-';
break;
case 'n':
if (flags & 0x020)
*(__builtin_va_arg(ap,quad_ptr_t)) = ret;
else
if (flags & 0x010)
*(__builtin_va_arg(ap,long_ptr_t)) = ret;
else if (flags & 0x040)
*(__builtin_va_arg(ap,short_ptr_t)) = ret;
else
*(__builtin_va_arg(ap,int_ptr_t)) = ret;
continue;
case 'O':
flags |= 0x010;
case 'o':
_uquad = (flags&0x020 ? (__builtin_va_arg(ap,unsigned long long)) : flags&0x010 ? (__builtin_va_arg(ap,u_long)) : flags&0x040 ? (u_long)(u_short)(__builtin_va_arg(ap,int)) : (u_long)(__builtin_va_arg(ap,u_int)));
base = OCT;
goto nosign;
case 'p':
# 914 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
_uquad = (u_long)(unsigned long)(__builtin_va_arg(ap,void_ptr_t));
base = HEX;
xdigs = "0123456789abcdef";
flags |= 0x002;
ch = 'x';
goto nosign;
case 's':
case 'S':
sign = '\0';
if ((cp = (__builtin_va_arg(ap,char_ptr_t))) == ((void *)0)) {
cp = "(null)";
size = 6;
}
else if (ch == 'S' || (flags & 0x010)) {
mbstate_t ps;
const wchar_t *wcp;
wcp = (const wchar_t *)cp;
size = m = 0;
memset((void *)&ps, '\0', sizeof(mbstate_t));
if (prec >= 0) {
while (1) {
if (wcp[m] == L'\0')
break;
if ((n = (int)_wcrtomb_r(data,
buf, wcp[m], &ps)) == -1)
goto error;
if (n + size > prec)
break;
m += 1;
size += n;
if (size == prec)
break;
}
}
else {
if ((size = (int)_wcsrtombs_r(data,
((void *)0), &wcp, 0, &ps)) == -1)
goto error;
wcp = (const wchar_t *)cp;
}
if (size == 0)
break;
if ((malloc_buf =
(char *)_malloc_r(data, size + 1)) == ((void *)0))
goto error;
memset((void *)&ps, '\0', sizeof(mbstate_t));
if (_wcsrtombs_r(data, malloc_buf,
&wcp, size, &ps) != size)
goto error;
cp = malloc_buf;
cp[size] = '\0';
}
else if (prec >= 0) {
char *p = memchr(cp, 0, prec);
if (p != ((void *)0)) {
size = p - cp;
if (size > prec)
size = prec;
} else
size = prec;
} else
size = strlen(cp);
break;
case 'U':
flags |= 0x010;
case 'u':
_uquad = (flags&0x020 ? (__builtin_va_arg(ap,unsigned long long)) : flags&0x010 ? (__builtin_va_arg(ap,u_long)) : flags&0x040 ? (u_long)(u_short)(__builtin_va_arg(ap,int)) : (u_long)(__builtin_va_arg(ap,u_int)));
base = DEC;
goto nosign;
case 'X':
xdigs = "0123456789ABCDEF";
goto hex;
case 'x':
xdigs = "0123456789abcdef";
hex: _uquad = (flags&0x020 ? (__builtin_va_arg(ap,unsigned long long)) : flags&0x010 ? (__builtin_va_arg(ap,u_long)) : flags&0x040 ? (u_long)(u_short)(__builtin_va_arg(ap,int)) : (u_long)(__builtin_va_arg(ap,u_int)));
base = HEX;
if (flags & 0x001 && _uquad != 0)
flags |= 0x002;
nosign: sign = '\0';
number: if ((dprec = prec) >= 0)
flags &= ~0x080;
cp = buf + (308 +39 +1);
if (_uquad != 0 || prec != 0) {
switch (base) {
case OCT:
do {
*--cp = ((_uquad & 7) + '0');
_uquad >>= 3;
} while (_uquad);
if (flags & 0x001 && *cp != '0')
*--cp = '0';
break;
case DEC:
while (_uquad >= 10) {
*--cp = ((_uquad % 10) + '0');
_uquad /= 10;
}
*--cp = ((_uquad) + '0');
break;
case HEX:
do {
*--cp = xdigs[_uquad & 15];
_uquad >>= 4;
} while (_uquad);
break;
default:
cp = "bug in vfprintf: bad base";
size = strlen(cp);
goto skipsize;
}
}
# 1075 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
else if (base == OCT && (flags & 0x001))
*--cp = '0';
size = buf + (308 +39 +1) - cp;
skipsize:
break;
default:
if (ch == '\0')
goto done;
cp = buf;
*cp = ch;
size = 1;
sign = '\0';
break;
}
# 1106 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
realsz = dprec > size ? dprec : size;
if (sign)
realsz++;
else if (flags & 0x002)
realsz+= 2;
if ((flags & (0x004|0x080)) == 0)
{ if ((n = (width - realsz)) > 0) { while (n > 16) { { iovp->iov_base = (blanks); iovp->iov_len = (16); uio.uio_resid += (16); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; n -= 16; } { iovp->iov_base = (blanks); iovp->iov_len = (n); uio.uio_resid += (n); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; } };
if (sign) {
{ iovp->iov_base = (&sign); iovp->iov_len = (1); uio.uio_resid += (1); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
} else if (flags & 0x002) {
ox[0] = '0';
ox[1] = ch;
{ iovp->iov_base = (ox); iovp->iov_len = (2); uio.uio_resid += (2); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
}
if ((flags & (0x004|0x080)) == 0x080)
{ if ((n = (width - realsz)) > 0) { while (n > 16) { { iovp->iov_base = (zeroes); iovp->iov_len = (16); uio.uio_resid += (16); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; n -= 16; } { iovp->iov_base = (zeroes); iovp->iov_len = (n); uio.uio_resid += (n); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; } };
{ if ((n = (dprec - size)) > 0) { while (n > 16) { { iovp->iov_base = (zeroes); iovp->iov_len = (16); uio.uio_resid += (16); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; n -= 16; } { iovp->iov_base = (zeroes); iovp->iov_len = (n); uio.uio_resid += (n); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; } };
if ((flags & 0x100) == 0) {
{ iovp->iov_base = (cp); iovp->iov_len = (size); uio.uio_resid += (size); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
} else {
if (ch >= 'f') {
if ((_double_.d) == 0) {
{ iovp->iov_base = ("0"); iovp->iov_len = (1); uio.uio_resid += (1); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
if (expt < ndig || (flags & 0x001) != 0) {
{ iovp->iov_base = (decimal_point); iovp->iov_len = (1); uio.uio_resid += (1); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
{ if ((n = (ndig - 1)) > 0) { while (n > 16) { { iovp->iov_base = (zeroes); iovp->iov_len = (16); uio.uio_resid += (16); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; n -= 16; } { iovp->iov_base = (zeroes); iovp->iov_len = (n); uio.uio_resid += (n); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; } };
}
} else if (expt <= 0) {
{ iovp->iov_base = ("0"); iovp->iov_len = (1); uio.uio_resid += (1); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
if(expt || ndig) {
{ iovp->iov_base = (decimal_point); iovp->iov_len = (1); uio.uio_resid += (1); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
{ if ((n = (-expt)) > 0) { while (n > 16) { { iovp->iov_base = (zeroes); iovp->iov_len = (16); uio.uio_resid += (16); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; n -= 16; } { iovp->iov_base = (zeroes); iovp->iov_len = (n); uio.uio_resid += (n); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; } };
{ iovp->iov_base = (cp); iovp->iov_len = (ndig); uio.uio_resid += (ndig); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
}
} else if (expt >= ndig) {
{ iovp->iov_base = (cp); iovp->iov_len = (ndig); uio.uio_resid += (ndig); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
{ if ((n = (expt - ndig)) > 0) { while (n > 16) { { iovp->iov_base = (zeroes); iovp->iov_len = (16); uio.uio_resid += (16); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; n -= 16; } { iovp->iov_base = (zeroes); iovp->iov_len = (n); uio.uio_resid += (n); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; } };
if (flags & 0x001)
{ iovp->iov_base = ("."); iovp->iov_len = (1); uio.uio_resid += (1); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
} else {
{ iovp->iov_base = (cp); iovp->iov_len = (expt); uio.uio_resid += (expt); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
cp += expt;
{ iovp->iov_base = ("."); iovp->iov_len = (1); uio.uio_resid += (1); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
{ iovp->iov_base = (cp); iovp->iov_len = (ndig-expt); uio.uio_resid += (ndig-expt); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
}
} else {
if (ndig > 1 || flags & 0x001) {
ox[0] = *cp++;
ox[1] = '.';
{ iovp->iov_base = (ox); iovp->iov_len = (2); uio.uio_resid += (2); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
if ((_double_.d)) {
{ iovp->iov_base = (cp); iovp->iov_len = (ndig-1); uio.uio_resid += (ndig-1); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
} else
{ if ((n = (ndig - 1)) > 0) { while (n > 16) { { iovp->iov_base = (zeroes); iovp->iov_len = (16); uio.uio_resid += (16); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; n -= 16; } { iovp->iov_base = (zeroes); iovp->iov_len = (n); uio.uio_resid += (n); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; } };
} else
{ iovp->iov_base = (cp); iovp->iov_len = (1); uio.uio_resid += (1); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
{ iovp->iov_base = (expstr); iovp->iov_len = (expsize); uio.uio_resid += (expsize); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } };
}
}
if (flags & 0x004)
{ if ((n = (width - realsz)) > 0) { while (n > 16) { { iovp->iov_base = (blanks); iovp->iov_len = (16); uio.uio_resid += (16); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; n -= 16; } { iovp->iov_base = (blanks); iovp->iov_len = (n); uio.uio_resid += (n); iovp++; if (++uio.uio_iovcnt >= 8) { if (__sprint(fp, &uio)) goto error; iovp = iov; } }; } };
ret += width > realsz ? width : realsz;
{ if (uio.uio_resid && __sprint(fp, &uio)) goto error; uio.uio_iovcnt = 0; iovp = iov; };
if (malloc_buf != ((void *)0)) {
free(malloc_buf);
malloc_buf = ((void *)0);
}
}
done:
{ if (uio.uio_resid && __sprint(fp, &uio)) goto error; uio.uio_iovcnt = 0; iovp = iov; };
error:
if (malloc_buf != ((void *)0))
free(malloc_buf);
return ((((fp)->_flags & 0x0040) != 0) ? (-1) : ret);
}
extern char *_dtoa_r (struct _reent *, double, int, int, int *, int *, char **);
# 1216 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
static char *
cvt(data, value, ndigits, flags, sign, decpt, ch, length)
struct _reent *data;
double value;
int ndigits, flags, *decpt, ch, *length;
char *sign;
{
int mode, dsgn;
char *digits, *bp, *rve;
union double_union tmp;
if (ch == 'f') {
mode = 3;
} else {
if (ch == 'e' || ch == 'E') {
ndigits++;
}
mode = 2;
}
tmp.d = value;
if ((tmp.i[0]) & ((__uint32_t)0x80000000L)) {
value = -value;
*sign = '-';
} else
*sign = '\000';
digits = _dtoa_r(data, value, mode, ndigits, decpt, &dsgn, &rve);
# 1269 "/src/sourceware/newlib/src/newlib/libc/stdio/vfprintf.c"
if ((ch != 'g' && ch != 'G') || flags & 0x001) {
bp = digits + ndigits;
if (ch == 'f') {
if (*digits == '0' && value)
*decpt = -ndigits + 1;
bp += *decpt;
}
if (value == 0)
rve = bp;
while (rve < bp)
*rve++ = '0';
}
*length = rve - digits;
return (digits);
}
static int
exponent(p0, exp, fmtch)
char *p0;
int exp, fmtch;
{
register char *p, *t;
char expbuf[40];
p = p0;
*p++ = fmtch;
if (exp < 0) {
exp = -exp;
*p++ = '-';
}
else
*p++ = '+';
t = expbuf + 40;
if (exp > 9) {
do {
*--t = ((exp % 10) + '0');
} while ((exp /= 10) > 9);
*--t = ((exp) + '0');
for (; t < expbuf + 40; *p++ = *t++);
}
else {
*p++ = '0';
*p++ = ((exp) + '0');
}
return (p - p0);
}
--
Summary: ICE in sh-elf-gcc with -m4-single-only and -O2
Product: gcc
Version: 3.5.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: fnf at redhat dot com
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: i686-pc-linux-gnu
GCC host triplet: i686-pc-linux-gnu
GCC target triplet: sh-unknown-elf
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14282