OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.c-torture/] [execute/] [builtins/] [lib/] [sprintf.c] - Blame information for rev 297

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 297 jeremybenn
#include <stdio.h>
2
#include <stdarg.h>
3
extern void abort (void);
4
extern int inside_main;
5
 
6
__attribute__ ((__noinline__))
7
int
8
(sprintf) (char *buf, const char *fmt, ...)
9
{
10
  va_list ap;
11
  int r;
12
#ifdef __OPTIMIZE__
13
  if (inside_main)
14
    abort ();
15
#endif
16
  va_start (ap, fmt);
17
  r = vsprintf (buf, fmt, ap);
18
  va_end (ap);
19
  return r;
20
}
21
 
22
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.