aboutsummaryrefslogtreecommitdiff
path: root/newlib/libc/machine/spu/vprintf.c
blob: d2ebc4eda3768cd2da81900af6c37984632182b1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#include <_ansi.h>
#include <stdio.h>

#include "c99ppe.h"

#include <stdarg.h>

#ifdef INTEGER_ONLY
#  define vprintf viprintf
#endif

typedef struct
{
  const char* fmt;
  unsigned int pad0[ 3 ];
  va_list ap;
} c99_vprintf_t;

#ifndef _REENT_ONLY

int
vprintf (const char *fmt,
     va_list ap)
{
  c99_vprintf_t args;

  args.fmt = fmt;
  va_copy(args.ap,ap);

  return __send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_VPRINTF, &args);
}

#endif /* ! _REENT_ONLY */