Ansi Library; Overview; Ansi Library Function List - Epson S5U1C17001C Manual

Cmos 16-bit single chip microcomputer, c compiler package for s1c17 family
Hide thumbs Also See for S5U1C17001C:
Table of Contents

Advertisement

7.3 anSi library

7.3.1 Overview

The S1C17 Family C Compiler Package contains an ANSI library.
Each function in this library has ANSI-standard functionality. Certain ANSI library functions not supported by this
package are not included in the ANSI library.
The client assumes responsibility for function implementation and prototype declarations when using ANSI library
functions not listed in Section 7.3.2, "ANSI Library Function List."
For some ANSI library functions not supported by this package, the header files include only prototype
declarations. In these cases, include the pertinent header file rather than declaring a prototype before implementing
the function.
See the table in Section 4.2.2, "Library Functions and Header Files" for a discussion of ANSI library functions with
prototype declarations only.
The libc.a ANSI library file is installed in separate directories (\gnu17\lib\24bit and \gnu17\lib\
16bit) for each memory model. A long long-type ANSI library is included in libgcc.a (libgccM.a/
libgccMD.a).
The following header files which contain definitions of each function are installed in the include directory.
stdio.h
stdlib.h
string.h
stdarg.h
registers used in the library
• The registers %r0 to %r7 are used.
• The registers %r4 to %r7 are protected by saving to the stack before execution of a function and by restoring
from the stack after completion of the function.

7.3.2 anSi library function list

The contents of the Reentrant column in the tables are as follows:
Reentrant:
Reentrant function
Nonreentrant: Non-reentrant function
Conditional:
Non-reentrant function (This function refers to a global variable. It can be used as a reentrant function
if there is no change in the global variable, and your created read() and write() are reentrant functions.)
input/output functions
The table below lists the input/output functions included in libc.a.
Header file: stdio.h
function
size_t fread(void *ptr, size_t size,
size_t count, FILE *stream);
size_t fwrite(void *ptr, size_t size,
size_t count, FILE *stream);
int fgetc(FILE *stream);
int getc(FILE *stream);
int getchar( );
int ungetc(int c, FILE *stream);
char *fgets(char *s, int n, FILE
*stream);
char *gets(char *s);
S5U1C17001C ManUal
(C COMPilEr PaCkagE fOr S1C17 faMily) (Ver. 1.5.0)
time.h
math.h
errno.h
setjmp.h
smcvals.h
Table 7.3.2.1 Input/output functions
functionality
Input array element from
stdin.
Output array element to
stdout.
Input one character from
stdin.
Input one character from
stdin.
Input one character from
stdin.
Push one character back
to input buffer.
Input character string
from stdin.
Input character string
from stdin.
EPSOn
float.h
limits.h
stddef.h
reentrant
Conditional Refer to global variables stdin and
_iob, and call read function.
Conditional Refer to global variables stdout, stderr
and _iob, and call write function.
Conditional Refer to global variables stdin and
_iob, and call read function.
Conditional Refer to global variables stdin and
iob, and call read function.
Conditional Refer to global variables stdin and
_iob, and call read function.
Nonreentrant Refer to global variables stdin, std-
out, stderr, and _iob, returned value
overwrite.
Conditional Refer to global variables stdin and
_iob, and call read function.
Conditional Refer to global variables stdin and
_iob, and call read function.
7 liBrary
7
Library
ctype.h
notes
7-9

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the S5U1C17001C and is the answer not in the manual?

Table of Contents