![](http://datasheet.mmic.net.cn/270000/78IV_datasheet_16009038/78IV_28.png)
CHAPTER 1 GENERAL
User
’
s Manual U15556EJ1V0UM
28
1.5 Features of This C Compiler
This C compiler has extended functions for CPU code generation that are not supported by ANSI (American
National Standards Institute) Standard C. The extended functions of the C compiler allow the special function
registers for the 78K/IV Series to be described at the C language level and thus help shorten object code and
improve program execution speed. For details of these extended functions, see
CHAPTER 11 EXTENDED
FUNCTIONS
in this manual.
Outlined here are the following extended functions that help shorten object code and improve execution speed.
callt
/_ _
callt
functions ..................
Register variables ..........................
sreg
/_ _
sreg
/_ _
sreg1
variablesVariables can be allocated to the
saddr
area.
sfr
area ..........................................
sfr
names can be used.
noauto
functions............................
Functions that do not output code for stack frame formation can be
norec
/_ _
leaf
functions..................
created.
ASM statements.............................
An assembly language program can be described in a C source
program.
bit
type variables,...........................
Accessing the
saddr
or
sfr
area can be made on a bit-by-bit basis.
boolean
/_ _
boolean
type variables,
_ _
boolean
1 type variables
callf
/_ _
callf
functions ...................
A function body can be stored in the
callf
area.
Bit field declaration ........................
A bit field can be specified with
unsigned char
type.
Multiplication function.....................
The code to multiply can be directly output with inline expansion.
Division function.............................
The code to divide can be directly output with inline expansion.
Rotate function...............................
The code to rotate can be directly output with inline expansion.
Absolute address function..............
Specific addresses in the memory space can be accessed.
Data insertion function ...................
Specific data and instructions can be directly embedded in the code
area.
_ _pascal function..........................
The used stack is corrected on the called function side.
Memory manipulation function ......
memcopy
and
memset
can be directly output with inline expansion.
callf
two-step branch function .......
A two-step branch function is performed in the
callf
area.
Three-byte address
reference/generation function .......
Three-byte address reference/generation is performed.
Functions can be called using the
callt
table area.
Variables can be allocated to registers.
An outline of the extended functions of this compiler is shown below. For details of each extended function, refer
to
CHAPTER 11
.
<1>
callt
/_ _
callt
functions
Functions can be called by using the
callt
table area. The address of each function to be called (this
function is called a
callt
function) is stored in the
callt
table from which it can be called later. This makes
code shorter than the ordinary call instruction and helps shorten object code.
<2> Register variables
Variables declared with the
register
storage class specifier are allocated to the register or
saddr
area.
Instructions to the variables allocated to a register or
saddr
area are shorter in code length than those to
memory. This helps shorten object and improves program execution speed as well.