Xtensa-Options.html 9.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180
  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. Copyright (C) 1991-2017 Free Software Foundation, Inc.
  5. Permission is granted to copy, distribute and/or modify this document
  6. under the terms of the GNU Free Documentation License, Version 1.3
  7. or any later version published by the Free Software Foundation;
  8. with no Invariant Sections, with no Front-Cover Texts, and with no
  9. Back-Cover Texts. A copy of the license is included in the
  10. section entitled "GNU Free Documentation License".
  11. -->
  12. <!-- Created by GNU Texinfo 5.2, http://www.gnu.org/software/texinfo/ -->
  13. <head>
  14. <title>Using as: Xtensa Options</title>
  15. <meta name="description" content="Using as: Xtensa Options">
  16. <meta name="keywords" content="Using as: Xtensa Options">
  17. <meta name="resource-type" content="document">
  18. <meta name="distribution" content="global">
  19. <meta name="Generator" content="makeinfo">
  20. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  21. <link href="index.html#Top" rel="start" title="Top">
  22. <link href="AS-Index.html#AS-Index" rel="index" title="AS Index">
  23. <link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
  24. <link href="Xtensa_002dDependent.html#Xtensa_002dDependent" rel="up" title="Xtensa-Dependent">
  25. <link href="Xtensa-Syntax.html#Xtensa-Syntax" rel="next" title="Xtensa Syntax">
  26. <link href="Xtensa_002dDependent.html#Xtensa_002dDependent" rel="prev" title="Xtensa-Dependent">
  27. <style type="text/css">
  28. <!--
  29. a.summary-letter {text-decoration: none}
  30. blockquote.smallquotation {font-size: smaller}
  31. div.display {margin-left: 3.2em}
  32. div.example {margin-left: 3.2em}
  33. div.indentedblock {margin-left: 3.2em}
  34. div.lisp {margin-left: 3.2em}
  35. div.smalldisplay {margin-left: 3.2em}
  36. div.smallexample {margin-left: 3.2em}
  37. div.smallindentedblock {margin-left: 3.2em; font-size: smaller}
  38. div.smalllisp {margin-left: 3.2em}
  39. kbd {font-style:oblique}
  40. pre.display {font-family: inherit}
  41. pre.format {font-family: inherit}
  42. pre.menu-comment {font-family: serif}
  43. pre.menu-preformatted {font-family: serif}
  44. pre.smalldisplay {font-family: inherit; font-size: smaller}
  45. pre.smallexample {font-size: smaller}
  46. pre.smallformat {font-family: inherit; font-size: smaller}
  47. pre.smalllisp {font-size: smaller}
  48. span.nocodebreak {white-space:nowrap}
  49. span.nolinebreak {white-space:nowrap}
  50. span.roman {font-family:serif; font-weight:normal}
  51. span.sansserif {font-family:sans-serif; font-weight:normal}
  52. ul.no-bullet {list-style: none}
  53. -->
  54. </style>
  55. </head>
  56. <body lang="en" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000">
  57. <a name="Xtensa-Options"></a>
  58. <div class="header">
  59. <p>
  60. Next: <a href="Xtensa-Syntax.html#Xtensa-Syntax" accesskey="n" rel="next">Xtensa Syntax</a>, Up: <a href="Xtensa_002dDependent.html#Xtensa_002dDependent" accesskey="u" rel="up">Xtensa-Dependent</a> &nbsp; [<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>
  61. </div>
  62. <hr>
  63. <a name="Command-Line-Options"></a>
  64. <h4 class="subsection">9.53.1 Command Line Options</h4>
  65. <dl compact="compact">
  66. <dt><code>--text-section-literals | --no-text-section-literals</code></dt>
  67. <dd><a name="index-_002d_002dtext_002dsection_002dliterals"></a>
  68. <a name="index-_002d_002dno_002dtext_002dsection_002dliterals"></a>
  69. <p>Control the treatment of literal pools. The default is
  70. &lsquo;<samp>--no-text-section-literals</samp>&rsquo;, which places literals in
  71. separate sections in the output file. This allows the literal pool to be
  72. placed in a data RAM/ROM. With &lsquo;<samp>--text-section-literals</samp>&rsquo;, the
  73. literals are interspersed in the text section in order to keep them as
  74. close as possible to their references. This may be necessary for large
  75. assembly files, where the literals would otherwise be out of range of the
  76. <code>L32R</code> instructions in the text section. Literals are grouped into
  77. pools following <code>.literal_position</code> directives or preceding
  78. <code>ENTRY</code> instructions. These options only affect literals referenced
  79. via PC-relative <code>L32R</code> instructions; literals for absolute mode
  80. <code>L32R</code> instructions are handled separately.
  81. See <a href="Literal-Directive.html#Literal-Directive">literal</a>.
  82. </p>
  83. </dd>
  84. <dt><code>--auto-litpools | --no-auto-litpools</code></dt>
  85. <dd><a name="index-_002d_002dauto_002dlitpools"></a>
  86. <a name="index-_002d_002dno_002dauto_002dlitpools"></a>
  87. <p>Control the treatment of literal pools. The default is
  88. &lsquo;<samp>--no-auto-litpools</samp>&rsquo;, which in the absence of
  89. &lsquo;<samp>--text-section-literals</samp>&rsquo; places literals in separate sections
  90. in the output file. This allows the literal pool to be placed in a data
  91. RAM/ROM. With &lsquo;<samp>--auto-litpools</samp>&rsquo;, the literals are interspersed
  92. in the text section in order to keep them as close as possible to their
  93. references, explicit <code>.literal_position</code> directives are not
  94. required. This may be necessary for very large functions, where single
  95. literal pool at the beginning of the function may not be reachable by
  96. <code>L32R</code> instructions at the end. These options only affect
  97. literals referenced via PC-relative <code>L32R</code> instructions; literals
  98. for absolute mode <code>L32R</code> instructions are handled separately.
  99. When used together with &lsquo;<samp>--text-section-literals</samp>&rsquo;,
  100. &lsquo;<samp>--auto-litpools</samp>&rsquo; takes precedence.
  101. See <a href="Literal-Directive.html#Literal-Directive">literal</a>.
  102. </p>
  103. </dd>
  104. <dt><code>--absolute-literals | --no-absolute-literals</code></dt>
  105. <dd><a name="index-_002d_002dabsolute_002dliterals"></a>
  106. <a name="index-_002d_002dno_002dabsolute_002dliterals"></a>
  107. <p>Indicate to the assembler whether <code>L32R</code> instructions use absolute
  108. or PC-relative addressing. If the processor includes the absolute
  109. addressing option, the default is to use absolute <code>L32R</code>
  110. relocations. Otherwise, only the PC-relative <code>L32R</code> relocations
  111. can be used.
  112. </p>
  113. </dd>
  114. <dt><code>--target-align | --no-target-align</code></dt>
  115. <dd><a name="index-_002d_002dtarget_002dalign"></a>
  116. <a name="index-_002d_002dno_002dtarget_002dalign"></a>
  117. <p>Enable or disable automatic alignment to reduce branch penalties at some
  118. expense in code size. See <a href="Xtensa-Automatic-Alignment.html#Xtensa-Automatic-Alignment">Automatic
  119. Instruction Alignment</a>. This optimization is enabled by default. Note
  120. that the assembler will always align instructions like <code>LOOP</code> that
  121. have fixed alignment requirements.
  122. </p>
  123. </dd>
  124. <dt><code>--longcalls | --no-longcalls</code></dt>
  125. <dd><a name="index-_002d_002dlongcalls"></a>
  126. <a name="index-_002d_002dno_002dlongcalls"></a>
  127. <p>Enable or disable transformation of call instructions to allow calls
  128. across a greater range of addresses. See <a href="Xtensa-Call-Relaxation.html#Xtensa-Call-Relaxation">Function Call Relaxation</a>. This option should be used when call
  129. targets can potentially be out of range. It may degrade both code size
  130. and performance, but the linker can generally optimize away the
  131. unnecessary overhead when a call ends up within range. The default is
  132. &lsquo;<samp>--no-longcalls</samp>&rsquo;.
  133. </p>
  134. </dd>
  135. <dt><code>--transform | --no-transform</code></dt>
  136. <dd><a name="index-_002d_002dtransform"></a>
  137. <a name="index-_002d_002dno_002dtransform"></a>
  138. <p>Enable or disable all assembler transformations of Xtensa instructions,
  139. including both relaxation and optimization. The default is
  140. &lsquo;<samp>--transform</samp>&rsquo;; &lsquo;<samp>--no-transform</samp>&rsquo; should only be used in the
  141. rare cases when the instructions must be exactly as specified in the
  142. assembly source. Using &lsquo;<samp>--no-transform</samp>&rsquo; causes out of range
  143. instruction operands to be errors.
  144. </p>
  145. </dd>
  146. <dt><code>--rename-section <var>oldname</var>=<var>newname</var></code></dt>
  147. <dd><a name="index-_002d_002drename_002dsection"></a>
  148. <p>Rename the <var>oldname</var> section to <var>newname</var>. This option can be used
  149. multiple times to rename multiple sections.
  150. </p>
  151. </dd>
  152. <dt><code>--trampolines | --no-trampolines</code></dt>
  153. <dd><a name="index-_002d_002dtrampolines"></a>
  154. <a name="index-_002d_002dno_002dtrampolines"></a>
  155. <p>Enable or disable transformation of jump instructions to allow jumps
  156. across a greater range of addresses. See <a href="Xtensa-Jump-Relaxation.html#Xtensa-Jump-Relaxation">Jump Trampolines</a>. This option should be used when jump targets can
  157. potentially be out of range. In the absence of such jumps this option
  158. does not affect code size or performance. The default is
  159. &lsquo;<samp>--trampolines</samp>&rsquo;.
  160. </p></dd>
  161. </dl>
  162. <hr>
  163. <div class="header">
  164. <p>
  165. Next: <a href="Xtensa-Syntax.html#Xtensa-Syntax" accesskey="n" rel="next">Xtensa Syntax</a>, Up: <a href="Xtensa_002dDependent.html#Xtensa_002dDependent" accesskey="u" rel="up">Xtensa-Dependent</a> &nbsp; [<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>
  166. </div>
  167. </body>
  168. </html>