⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 sh64-addressing.html

📁 gcc手册
💻 HTML
字号:
<html lang="en">

<head>

<title>Using as</title>

<meta http-equiv="Content-Type" content="text/html">

<meta name="description" content="Using as">

<meta name="generator" content="makeinfo 4.3">

<link href="http://www.gnu.org/software/texinfo/" rel="generator-home">

</head>

<body>

<div class="node">

<p>

Node:<a name="SH64-Addressing">SH64-Addressing</a>,

Previous:<a rel="previous" accesskey="p" href="SH64-Regs.html#SH64-Regs">SH64-Regs</a>,

Up:<a rel="up" accesskey="u" href="SH64-Syntax.html#SH64%20Syntax">SH64 Syntax</a>

<hr><br>

</div>



<h5 class="subsection">Addressing Modes</h5>



   <p>SH64 operands consist of either a register or immediate value.  The

immediate value can be a constant or label reference (or portion of a

label reference), as in this example:



<pre class="example">     	movi	4,r2

     	pt	function, tr4

     	movi	(function &gt;&gt; 16) &amp; 65535,r0

     	shori	function &amp; 65535, r0

     	ld.l	r0,4,r0

     </pre>



   <p>Instruction label references can reference labels in either SHmedia or

SHcompact.  To differentiate between the two, labels in SHmedia sections

will always have the least significant bit set (i.e. they will be odd),

which SHcompact labels will have the least significant bit reset

(i.e. they will be even).  If you need to reference the actual address

of a label, you can use the <code>datalabel</code> modifier, as in this

example:



<pre class="example">     	.long	function

     	.long	datalabel function

     </pre>



   <p>In that example, the first longword may or may not have the least

significant bit set depending on whether the label is an SHmedia label

or an SHcompact label.  The second longword will be the actual address

of the label, regardless of what type of lable it is.



   </body></html>



⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -