neingeist
/
arduinisten
Archived
1
0
Fork 0
You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

103 lines
4.4 KiB
HTML

<html lang="en">
<head>
<title>ESA/390 Syntax - Using as</title>
<meta http-equiv="Content-Type" content="text/html">
<meta name="description" content="Using as">
<meta name="generator" content="makeinfo 4.7">
<link title="Top" rel="start" href="index.html#Top">
<link rel="up" href="ESA_002f390_002dDependent.html#ESA_002f390_002dDependent" title="ESA/390-Dependent">
<link rel="prev" href="ESA_002f390-Options.html#ESA_002f390-Options" title="ESA/390 Options">
<link rel="next" href="ESA_002f390-Floating-Point.html#ESA_002f390-Floating-Point" title="ESA/390 Floating Point">
<link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage">
<!--
This file documents the GNU Assembler "as".
Copyright (C) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002,
2006, 2007 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
section entitled ``GNU Free Documentation License''.
man end-->
<meta http-equiv="Content-Style-Type" content="text/css">
<style type="text/css"><!--
pre.display { font-family:inherit }
pre.format { font-family:inherit }
pre.smalldisplay { font-family:inherit; font-size:smaller }
pre.smallformat { font-family:inherit; font-size:smaller }
pre.smallexample { font-size:smaller }
pre.smalllisp { font-size:smaller }
span.sc { font-variant:small-caps }
span.roman { font-family: serif; font-weight: normal; }
--></style>
</head>
<body>
<div class="node">
<p>
<a name="ESA_002f390-Syntax"></a>Next:&nbsp;<a rel="next" accesskey="n" href="ESA_002f390-Floating-Point.html#ESA_002f390-Floating-Point">ESA/390 Floating Point</a>,
Previous:&nbsp;<a rel="previous" accesskey="p" href="ESA_002f390-Options.html#ESA_002f390-Options">ESA/390 Options</a>,
Up:&nbsp;<a rel="up" accesskey="u" href="ESA_002f390_002dDependent.html#ESA_002f390_002dDependent">ESA/390-Dependent</a>
<hr><br>
</div>
<h4 class="subsection">9.12.3 Syntax</h4>
<p>The opcode/operand syntax follows the ESA/390 Principles of Operation
manual; assembler directives and general syntax are loosely based on the
prevailing AT&amp;T/SVR4/ELF/Solaris style notation. HLASM-style directives
are <em>not</em> supported for the most part, with the exception of those
described herein.
<p>A leading dot in front of directives is optional, and the case of
directives is ignored; thus for example, .using and USING have the same
effect.
<p>A colon may immediately follow a label definition. This is
simply for compatibility with how most assembly language programmers
write code.
<p><span class="samp">#</span> is the line comment character.
<p><span class="samp">;</span> can be used instead of a newline to separate statements.
<p>Since <span class="samp">$</span> has no special meaning, you may use it in symbol names.
<p>Registers can be given the symbolic names r0..r15, fp0, fp2, fp4, fp6.
By using thesse symbolic names, <code>as</code> can detect simple
syntax errors. The name rarg or r.arg is a synonym for r11, rtca or r.tca
for r12, sp, r.sp, dsa r.dsa for r13, lr or r.lr for r14, rbase or r.base
for r3 and rpgt or r.pgt for r4.
<p><span class="samp">*</span> is the current location counter. Unlike <span class="samp">.</span> it is always
relative to the last USING directive. Note that this means that
expressions cannot use multiplication, as any occurrence of <span class="samp">*</span>
will be interpreted as a location counter.
<p>All labels are relative to the last USING. Thus, branches to a label
always imply the use of base+displacement.
<p>Many of the usual forms of address constants / address literals
are supported. Thus,
<pre class="example"> .using *,r3
L r15,=A(some_routine)
LM r6,r7,=V(some_longlong_extern)
A r1,=F'12'
AH r0,=H'42'
ME r6,=E'3.1416'
MD r6,=D'3.14159265358979'
O r6,=XL4'cacad0d0'
.ltorg
</pre>
<p>should all behave as expected: that is, an entry in the literal
pool will be created (or reused if it already exists), and the
instruction operands will be the displacement into the literal pool
using the current base register (as last declared with the <code>.using</code>
directive).
</body></html>