Sophie

Sophie

distrib > Fedora > 14 > x86_64 > media > updates > by-pkgid > e677bbbdff6d27fe001f15e0ef2bb4cc > files > 253

sdcc-3.0.0-0.fc14.x86_64.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">

<!--Converted with LaTeX2HTML 2008 (1.71)
original version by:  Nikos Drakos, CBLU, University of Leeds
* revised and updated by:  Marcus Hennecke, Ross Moore, Herb Swan
* with significant contributions from:
  Jens Lippmann, Marek Rouchal, Martin Wilck and others -->
<HTML>
<HEAD>
<TITLE>3.14.2 Registers usage</TITLE>
<META NAME="description" CONTENT="3.14.2 Registers usage">
<META NAME="keywords" CONTENT="sdccman">
<META NAME="resource-type" CONTENT="document">
<META NAME="distribution" CONTENT="global">

<META NAME="Generator" CONTENT="LaTeX2HTML v2008">
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">

<LINK REL="STYLESHEET" HREF="sdccman.css">

<LINK REL="next" HREF="node88.html">
<LINK REL="previous" HREF="node86.html">
<LINK REL="up" HREF="node85.html">
<LINK REL="next" HREF="node88.html">
</HEAD>

<BODY >
<!--Navigation Panel-->
<A NAME="tex2html1979"
  HREF="node88.html">
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" SRC="next.png"></A> 
<A NAME="tex2html1973"
  HREF="node85.html">
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" SRC="up.png"></A> 
<A NAME="tex2html1967"
  HREF="node86.html">
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" SRC="prev.png"></A> 
<A NAME="tex2html1975"
  HREF="node1.html">
<IMG WIDTH="65" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="contents" SRC="contents.png"></A> 
<A NAME="tex2html1977"
  HREF="node191.html">
<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" SRC="index.png"></A> 
<BR>
<B> Next:</B> <A NAME="tex2html1980"
  HREF="node88.html">3.14.3 Assembler Routine (non-reentrant)</A>
<B> Up:</B> <A NAME="tex2html1974"
  HREF="node85.html">3.14 Interfacing with Assembler</A>
<B> Previous:</B> <A NAME="tex2html1968"
  HREF="node86.html">3.14.1 Global Registers used</A>
 &nbsp; <B>  <A NAME="tex2html1976"
  HREF="node1.html">Contents</A></B> 
 &nbsp; <B>  <A NAME="tex2html1978"
  HREF="node191.html">Index</A></B> 
<BR>
<BR>
<!--End of Navigation Panel-->

<H2><A NAME="SECTION004142000000000000000">
3.14.2 Registers usage</A>
</H2>

<P>
Unless the called function is declared as <TT>_naked</TT><A NAME="2367"></A>,
or the --callee-saves<A NAME="2368"></A>/--all-callee-saves
command line option or the corresponding callee_saves pragma are
used, the caller will save the registers (<I>R0-R7</I>) around the
call, so the called function can destroy they content freely.

<P>
If the called function is not declared as <TT>_naked</TT>, the caller
will swap register banks around the call, if caller and callee use
different register banks (having them defined by the <TT>_using</TT>
modifier). 

<P>
The called function can also use <I>DPL</I>, <I>DPH</I>, <I>B</I>
and <I>ACC</I> observing that they are used for parameter/return value
passing.

<P>
<BR><HR>
<ADDRESS>

2011-03-20
</ADDRESS>
</BODY>
</HTML>