1<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> 2<html> 3<!-- This file documents the GNU Assembler "as". 4 5Copyright (C) 1991-2021 Free Software Foundation, Inc. 6 7Permission is granted to copy, distribute and/or modify this document 8under the terms of the GNU Free Documentation License, Version 1.3 9or any later version published by the Free Software Foundation; 10with no Invariant Sections, with no Front-Cover Texts, and with no 11Back-Cover Texts. A copy of the license is included in the 12section entitled "GNU Free Documentation License". 13 --> 14<!-- Created by GNU Texinfo 5.1, http://www.gnu.org/software/texinfo/ --> 15<head> 16<title>Using as: Z80 Options</title> 17 18<meta name="description" content="Using as: Z80 Options"> 19<meta name="keywords" content="Using as: Z80 Options"> 20<meta name="resource-type" content="document"> 21<meta name="distribution" content="global"> 22<meta name="Generator" content="makeinfo"> 23<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> 24<link href="index.html#Top" rel="start" title="Top"> 25<link href="AS-Index.html#AS-Index" rel="index" title="AS Index"> 26<link href="index.html#SEC_Contents" rel="contents" title="Table of Contents"> 27<link href="Z80_002dDependent.html#Z80_002dDependent" rel="up" title="Z80-Dependent"> 28<link href="Z80-Syntax.html#Z80-Syntax" rel="next" title="Z80 Syntax"> 29<link href="Z80_002dDependent.html#Z80_002dDependent" rel="previous" title="Z80-Dependent"> 30<style type="text/css"> 31<!-- 32a.summary-letter {text-decoration: none} 33blockquote.smallquotation {font-size: smaller} 34div.display {margin-left: 3.2em} 35div.example {margin-left: 3.2em} 36div.indentedblock {margin-left: 3.2em} 37div.lisp {margin-left: 3.2em} 38div.smalldisplay {margin-left: 3.2em} 39div.smallexample {margin-left: 3.2em} 40div.smallindentedblock {margin-left: 3.2em; font-size: smaller} 41div.smalllisp {margin-left: 3.2em} 42kbd {font-style:oblique} 43pre.display {font-family: inherit} 44pre.format {font-family: inherit} 45pre.menu-comment {font-family: serif} 46pre.menu-preformatted {font-family: serif} 47pre.smalldisplay {font-family: inherit; font-size: smaller} 48pre.smallexample {font-size: smaller} 49pre.smallformat {font-family: inherit; font-size: smaller} 50pre.smalllisp {font-size: smaller} 51span.nocodebreak {white-space:nowrap} 52span.nolinebreak {white-space:nowrap} 53span.roman {font-family:serif; font-weight:normal} 54span.sansserif {font-family:sans-serif; font-weight:normal} 55ul.no-bullet {list-style: none} 56--> 57</style> 58 59 60</head> 61 62<body lang="en" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000"> 63<a name="Z80-Options"></a> 64<div class="header"> 65<p> 66Next: <a href="Z80-Syntax.html#Z80-Syntax" accesskey="n" rel="next">Z80 Syntax</a>, Up: <a href="Z80_002dDependent.html#Z80_002dDependent" accesskey="u" rel="up">Z80-Dependent</a> [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="AS-Index.html#AS-Index" title="Index" rel="index">Index</a>]</p> 67</div> 68<hr> 69<a name="Command_002dline-Options-3"></a> 70<h4 class="subsection">9.56.1 Command-line Options</h4> 71<a name="index-Z80-options"></a> 72<a name="index-options-for-Z80"></a> 73<dl compact="compact"> 74<dd> 75<a name="index-_002dmarch_003d-command_002dline-option_002c-Z80"></a> 76</dd> 77<dt><code>-march=<var>CPU</var>[-<var>EXT</var>…][+<var>EXT</var>…]</code></dt> 78<dd><p>This option specifies the target processor. The assembler will issue 79an error message if an attempt is made to assemble an instruction which 80will not execute on the target processor. The following processor names 81are recognized: 82<code>z80</code>, 83<code>z180</code>, 84<code>ez80</code>, 85<code>gbz80</code>, 86<code>z80n</code>, 87<code>r800</code>. 88In addition to the basic instruction set, the assembler can be told to 89accept some extention mnemonics. For example, 90<code>-march=z180+sli+infc</code> extends <var>z180</var> with <var>SLI</var> instructions and 91<var>IN F,(C)</var>. The following extentions are currently supported: 92<code>full</code> (all known instructions), 93<code>adl</code> (ADL CPU mode by default, eZ80 only), 94<code>sli</code> (instruction known as <var>SLI</var>, <var>SLL</var> or <var>SL1</var>), 95<code>xyhl</code> (instructions with halves of index registers: <var>IXL</var>, <var>IXH</var>, 96<var>IYL</var>, <var>IYH</var>), 97<code>xdcb</code> (instructions like <var>RotOp (II+d),R</var> and <var>BitOp n,(II+d),R</var>), 98<code>infc</code> (instruction <var>IN F,(C)</var> or <var>IN (C)</var>), 99<code>outc0</code> (instruction <var>OUT (C),0</var>). 100Note that rather than extending a basic instruction set, the extention 101mnemonics starting with <code>-</code> revoke the respective functionality: 102<code>-march=z80-full+xyhl</code> first removes all default extentions and adds 103support for index registers halves only. 104</p> 105<p>If this option is not specified then <code>-march=z80+xyhl+infc</code> is assumed. 106</p> 107<a name="index-_002dlocal_002dprefix-command_002dline-option_002c-Z80"></a> 108</dd> 109<dt><code>-local-prefix=<var>prefix</var></code></dt> 110<dd><p>Mark all labels with specified prefix as local. But such label can be 111marked global explicitly in the code. This option do not change default 112local label prefix <code>.L</code>, it is just adds new one. 113</p> 114<a name="index-_002dcolonless-command_002dline-option_002c-Z80"></a> 115</dd> 116<dt><code>-colonless</code></dt> 117<dd><p>Accept colonless labels. All symbols at line begin are treated as labels. 118</p> 119<a name="index-_002dsdcc-command_002dline-option_002c-Z80"></a> 120</dd> 121<dt><code>-sdcc</code></dt> 122<dd><p>Accept assembler code produced by SDCC. 123</p> 124<a name="index-_002dfp_002ds-command_002dline-option_002c-Z80"></a> 125</dd> 126<dt><code>-fp-s=<var>FORMAT</var></code></dt> 127<dd><p>Single precision floating point numbers format. Default: ieee754 (32 bit). 128</p> 129<a name="index-_002dfp_002dd-command_002dline-option_002c-Z80"></a> 130</dd> 131<dt><code>-fp-d=<var>FORMAT</var></code></dt> 132<dd><p>Double precision floating point numbers format. Default: ieee754 (64 bit). 133</p></dd> 134</dl> 135 136<p>Floating point numbers formats. 137</p><dl compact="compact"> 138<dt><samp><code>ieee754</code></samp></dt> 139<dd><p>Single or double precision IEEE754 compatible format. 140</p> 141</dd> 142<dt><samp><code>half</code></samp></dt> 143<dd><p>Half precision IEEE754 compatible format (16 bits). 144</p> 145</dd> 146<dt><samp><code>single</code></samp></dt> 147<dd><p>Single precision IEEE754 compatible format (32 bits). 148</p> 149</dd> 150<dt><samp><code>double</code></samp></dt> 151<dd><p>Double precision IEEE754 compatible format (64 bits). 152</p> 153</dd> 154<dt><samp><code>zeda32</code></samp></dt> 155<dd><p>32 bit floating point format from z80float library by Zeda. 156</p> 157</dd> 158<dt><samp><code>math48</code></samp></dt> 159<dd><p>48 bit floating point format from Math48 package by Anders Hejlsberg. 160</p></dd> 161</dl> 162 163<a name="index-Z80-Syntax"></a> 164<hr> 165<div class="header"> 166<p> 167Next: <a href="Z80-Syntax.html#Z80-Syntax" accesskey="n" rel="next">Z80 Syntax</a>, Up: <a href="Z80_002dDependent.html#Z80_002dDependent" accesskey="u" rel="up">Z80-Dependent</a> [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="AS-Index.html#AS-Index" title="Index" rel="index">Index</a>]</p> 168</div> 169 170 171 172</body> 173</html> 174