EasyManua.ls Logo

Texas Instruments TMS34010 - Page 124

Texas Instruments TMS34010
128 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Appendix
E
ISP(96),STK,1
SP.A7,FP
2
globl
_function3
jFunctions
that
have
parameters
must
clean
up
their
own
stack.
This
is
done
by
placing
the
old
system
stack
pointer
back
into into
STK.
The
96
comes
from
64
bits
(A7
and
FP)
and
32
bits
for
the
return
PC.
jRestore
all registers
that
were
used
jPOP
off
the
return
PC
and
the
two
words
of
the
old
system
stack
pointer
111"11'11"11111111'111."'.'.1.'.'
••••••
".".".,"
,
FUNCTION
DEF
:
_function3
'.11"""'.'1,."".""".""""
••
"",.",1."",
function3:
MMTM
SP.A7.FP
;Save
all
register~
to
be
used
MOYE
STK,FP
jCreate
new
local
frame
ADDI
48,STK
jOne
32
bit
variable
and
one
char,
chars
are
stored
in
16
bits
for
efficiency
MOVa
'FP(-32),A7
jExtract
parmi
(8
bit
char)
MOVE
A7,'FP,1
HOVE
'FP(-192).IFP(O),1
ilocal
variable
=
struct_parm.struct_elementl
HOVa
'FP(-48)
,A7
jlocal
variable
=
HOVE
A1,'fP,\
struct
__
parm.
struct_e
I
ement3[
10)
HOVE
IFP(-224),A7,\
;
local
variable2
=
HOVa
A7,'fP(321
parm2
EPIO
4:
HOVE
'SP(96)
,STK,
I
HMfM
SP.A7.fP
RETS
2
end
E-5

Table of Contents

Other manuals for Texas Instruments TMS34010

Related product manuals