72
Chapter 3 Functions
3.2 Functions
ENTER function
Build stack frame
[ Description Example ]
ENTER
#3
[ Related Instructions ]
EXITD
ENTER
ENTER
[ Flag Change ]
[ Operation ]
SP
SP – 2
M(SP) FB
FB
SP
SP
SP – src
[ Syntax ]
ENTER
src
src
#IMM8
[ Selectable src ]
U
I
O
B
S
Z
D
C
[ Instruction Code/Number of Cycles ]
Page=177
Flag
Change
Return address (L)
Return address (M)
Return address (H)
Argument of function
SP
FB
SP
After instruction execution
Auto variable area
Direction in
which address
increases
Number of bytes
indicated by
src
FB (L)
FB (H)
Return address (L)
Return address (M)
Return address (H)
Argument of function
Before instruction execution
[ Function ]
• This instruction generates a stack frame.
src
represents the size of the stack frame.
• The diagrams below show the stack area status before and after the ENTER instruction is executed at
the beginning of a called subroutine.
Содержание R8C/Tiny Series
Страница 50: ...Chapter 3 Functions 3 1 Guide to This Chapter 3 2 Functions...
Страница 151: ...134 Chapter 3 Functions 3 2 Functions Blank for page layout...
Страница 152: ...Chapter 4 Instruction Code Number of Cycles 4 1 Guide to This Chapter 4 2 Instruction Code Number of Cycles...
Страница 278: ...Chapter 6 Calculation Number of Cycles 6 1 Instruction queue buffer...
Страница 287: ...Glossary 1 Glossary Technical terms used in this software manual are explained below They are good in this manual only...
Страница 291: ...Symbol 1 Table of symbols Symbols used in this software manual are explained below They are good in this manual only...
Страница 295: ...REVISION HISTORY R8C Tiny Series SOFTWARE MANUAL Rev Date Description Page Summary B 1 1 00 Jun 19 03 First Edition...
Страница 297: ...R8C Tiny Series Software Manual 2 6 2 Ote machi Chiyoda ku Tokyo 100 0004 Japan...