No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.

DEC-Alpha-Options.html 18KB

hace 3 años
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2. <html>
  3. <!-- Copyright (C) 1988-2020 Free Software Foundation, Inc.
  4. Permission is granted to copy, distribute and/or modify this document
  5. under the terms of the GNU Free Documentation License, Version 1.3 or
  6. any later version published by the Free Software Foundation; with the
  7. Invariant Sections being "Funding Free Software", the Front-Cover
  8. Texts being (a) (see below), and with the Back-Cover Texts being (b)
  9. (see below). A copy of the license is included in the section entitled
  10. "GNU Free Documentation License".
  11. (a) The FSF's Front-Cover Text is:
  12. A GNU Manual
  13. (b) The FSF's Back-Cover Text is:
  14. You have freedom to copy and modify this GNU Manual, like GNU
  15. software. Copies published by the Free Software Foundation raise
  16. funds for GNU development. -->
  17. <!-- Created by GNU Texinfo 6.5, http://www.gnu.org/software/texinfo/ -->
  18. <head>
  19. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  20. <title>DEC Alpha Options (Using the GNU Compiler Collection (GCC))</title>
  21. <meta name="description" content="DEC Alpha Options (Using the GNU Compiler Collection (GCC))">
  22. <meta name="keywords" content="DEC Alpha Options (Using the GNU Compiler Collection (GCC))">
  23. <meta name="resource-type" content="document">
  24. <meta name="distribution" content="global">
  25. <meta name="Generator" content="makeinfo">
  26. <link href="index.html#Top" rel="start" title="Top">
  27. <link href="Option-Index.html#Option-Index" rel="index" title="Option Index">
  28. <link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
  29. <link href="Submodel-Options.html#Submodel-Options" rel="up" title="Submodel Options">
  30. <link href="eBPF-Options.html#eBPF-Options" rel="next" title="eBPF Options">
  31. <link href="Darwin-Options.html#Darwin-Options" rel="prev" title="Darwin Options">
  32. <style type="text/css">
  33. <!--
  34. a.summary-letter {text-decoration: none}
  35. blockquote.indentedblock {margin-right: 0em}
  36. blockquote.smallindentedblock {margin-right: 0em; font-size: smaller}
  37. blockquote.smallquotation {font-size: smaller}
  38. div.display {margin-left: 3.2em}
  39. div.example {margin-left: 3.2em}
  40. div.lisp {margin-left: 3.2em}
  41. div.smalldisplay {margin-left: 3.2em}
  42. div.smallexample {margin-left: 3.2em}
  43. div.smalllisp {margin-left: 3.2em}
  44. kbd {font-style: oblique}
  45. pre.display {font-family: inherit}
  46. pre.format {font-family: inherit}
  47. pre.menu-comment {font-family: serif}
  48. pre.menu-preformatted {font-family: serif}
  49. pre.smalldisplay {font-family: inherit; font-size: smaller}
  50. pre.smallexample {font-size: smaller}
  51. pre.smallformat {font-family: inherit; font-size: smaller}
  52. pre.smalllisp {font-size: smaller}
  53. span.nolinebreak {white-space: nowrap}
  54. span.roman {font-family: initial; font-weight: normal}
  55. span.sansserif {font-family: sans-serif; font-weight: normal}
  56. ul.no-bullet {list-style: none}
  57. -->
  58. </style>
  59. </head>
  60. <body lang="en">
  61. <a name="DEC-Alpha-Options"></a>
  62. <div class="header">
  63. <p>
  64. Next: <a href="eBPF-Options.html#eBPF-Options" accesskey="n" rel="next">eBPF Options</a>, Previous: <a href="Darwin-Options.html#Darwin-Options" accesskey="p" rel="prev">Darwin Options</a>, Up: <a href="Submodel-Options.html#Submodel-Options" accesskey="u" rel="up">Submodel Options</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Option-Index.html#Option-Index" title="Index" rel="index">Index</a>]</p>
  65. </div>
  66. <hr>
  67. <a name="DEC-Alpha-Options-1"></a>
  68. <h4 class="subsection">3.19.13 DEC Alpha Options</h4>
  69. <p>These &lsquo;<samp>-m</samp>&rsquo; options are defined for the DEC Alpha implementations:
  70. </p>
  71. <dl compact="compact">
  72. <dt><code>-mno-soft-float</code></dt>
  73. <dt><code>-msoft-float</code></dt>
  74. <dd><a name="index-mno_002dsoft_002dfloat"></a>
  75. <a name="index-msoft_002dfloat-2"></a>
  76. <p>Use (do not use) the hardware floating-point instructions for
  77. floating-point operations. When <samp>-msoft-float</samp> is specified,
  78. functions in <samp>libgcc.a</samp> are used to perform floating-point
  79. operations. Unless they are replaced by routines that emulate the
  80. floating-point operations, or compiled in such a way as to call such
  81. emulations routines, these routines issue floating-point
  82. operations. If you are compiling for an Alpha without floating-point
  83. operations, you must ensure that the library is built so as not to call
  84. them.
  85. </p>
  86. <p>Note that Alpha implementations without floating-point operations are
  87. required to have floating-point registers.
  88. </p>
  89. </dd>
  90. <dt><code>-mfp-reg</code></dt>
  91. <dt><code>-mno-fp-regs</code></dt>
  92. <dd><a name="index-mfp_002dreg"></a>
  93. <a name="index-mno_002dfp_002dregs"></a>
  94. <p>Generate code that uses (does not use) the floating-point register set.
  95. <samp>-mno-fp-regs</samp> implies <samp>-msoft-float</samp>. If the floating-point
  96. register set is not used, floating-point operands are passed in integer
  97. registers as if they were integers and floating-point results are passed
  98. in <code>$0</code> instead of <code>$f0</code>. This is a non-standard calling sequence,
  99. so any function with a floating-point argument or return value called by code
  100. compiled with <samp>-mno-fp-regs</samp> must also be compiled with that
  101. option.
  102. </p>
  103. <p>A typical use of this option is building a kernel that does not use,
  104. and hence need not save and restore, any floating-point registers.
  105. </p>
  106. </dd>
  107. <dt><code>-mieee</code></dt>
  108. <dd><a name="index-mieee"></a>
  109. <p>The Alpha architecture implements floating-point hardware optimized for
  110. maximum performance. It is mostly compliant with the IEEE floating-point
  111. standard. However, for full compliance, software assistance is
  112. required. This option generates code fully IEEE-compliant code
  113. <em>except</em> that the <var>inexact-flag</var> is not maintained (see below).
  114. If this option is turned on, the preprocessor macro <code>_IEEE_FP</code> is
  115. defined during compilation. The resulting code is less efficient but is
  116. able to correctly support denormalized numbers and exceptional IEEE
  117. values such as not-a-number and plus/minus infinity. Other Alpha
  118. compilers call this option <samp>-ieee_with_no_inexact</samp>.
  119. </p>
  120. </dd>
  121. <dt><code>-mieee-with-inexact</code></dt>
  122. <dd><a name="index-mieee_002dwith_002dinexact"></a>
  123. <p>This is like <samp>-mieee</samp> except the generated code also maintains
  124. the IEEE <var>inexact-flag</var>. Turning on this option causes the
  125. generated code to implement fully-compliant IEEE math. In addition to
  126. <code>_IEEE_FP</code>, <code>_IEEE_FP_EXACT</code> is defined as a preprocessor
  127. macro. On some Alpha implementations the resulting code may execute
  128. significantly slower than the code generated by default. Since there is
  129. very little code that depends on the <var>inexact-flag</var>, you should
  130. normally not specify this option. Other Alpha compilers call this
  131. option <samp>-ieee_with_inexact</samp>.
  132. </p>
  133. </dd>
  134. <dt><code>-mfp-trap-mode=<var>trap-mode</var></code></dt>
  135. <dd><a name="index-mfp_002dtrap_002dmode"></a>
  136. <p>This option controls what floating-point related traps are enabled.
  137. Other Alpha compilers call this option <samp>-fptm <var>trap-mode</var></samp>.
  138. The trap mode can be set to one of four values:
  139. </p>
  140. <dl compact="compact">
  141. <dt>&lsquo;<samp>n</samp>&rsquo;</dt>
  142. <dd><p>This is the default (normal) setting. The only traps that are enabled
  143. are the ones that cannot be disabled in software (e.g., division by zero
  144. trap).
  145. </p>
  146. </dd>
  147. <dt>&lsquo;<samp>u</samp>&rsquo;</dt>
  148. <dd><p>In addition to the traps enabled by &lsquo;<samp>n</samp>&rsquo;, underflow traps are enabled
  149. as well.
  150. </p>
  151. </dd>
  152. <dt>&lsquo;<samp>su</samp>&rsquo;</dt>
  153. <dd><p>Like &lsquo;<samp>u</samp>&rsquo;, but the instructions are marked to be safe for software
  154. completion (see Alpha architecture manual for details).
  155. </p>
  156. </dd>
  157. <dt>&lsquo;<samp>sui</samp>&rsquo;</dt>
  158. <dd><p>Like &lsquo;<samp>su</samp>&rsquo;, but inexact traps are enabled as well.
  159. </p></dd>
  160. </dl>
  161. </dd>
  162. <dt><code>-mfp-rounding-mode=<var>rounding-mode</var></code></dt>
  163. <dd><a name="index-mfp_002drounding_002dmode"></a>
  164. <p>Selects the IEEE rounding mode. Other Alpha compilers call this option
  165. <samp>-fprm <var>rounding-mode</var></samp>. The <var>rounding-mode</var> can be one
  166. of:
  167. </p>
  168. <dl compact="compact">
  169. <dt>&lsquo;<samp>n</samp>&rsquo;</dt>
  170. <dd><p>Normal IEEE rounding mode. Floating-point numbers are rounded towards
  171. the nearest machine number or towards the even machine number in case
  172. of a tie.
  173. </p>
  174. </dd>
  175. <dt>&lsquo;<samp>m</samp>&rsquo;</dt>
  176. <dd><p>Round towards minus infinity.
  177. </p>
  178. </dd>
  179. <dt>&lsquo;<samp>c</samp>&rsquo;</dt>
  180. <dd><p>Chopped rounding mode. Floating-point numbers are rounded towards zero.
  181. </p>
  182. </dd>
  183. <dt>&lsquo;<samp>d</samp>&rsquo;</dt>
  184. <dd><p>Dynamic rounding mode. A field in the floating-point control register
  185. (<var>fpcr</var>, see Alpha architecture reference manual) controls the
  186. rounding mode in effect. The C library initializes this register for
  187. rounding towards plus infinity. Thus, unless your program modifies the
  188. <var>fpcr</var>, &lsquo;<samp>d</samp>&rsquo; corresponds to round towards plus infinity.
  189. </p></dd>
  190. </dl>
  191. </dd>
  192. <dt><code>-mtrap-precision=<var>trap-precision</var></code></dt>
  193. <dd><a name="index-mtrap_002dprecision"></a>
  194. <p>In the Alpha architecture, floating-point traps are imprecise. This
  195. means without software assistance it is impossible to recover from a
  196. floating trap and program execution normally needs to be terminated.
  197. GCC can generate code that can assist operating system trap handlers
  198. in determining the exact location that caused a floating-point trap.
  199. Depending on the requirements of an application, different levels of
  200. precisions can be selected:
  201. </p>
  202. <dl compact="compact">
  203. <dt>&lsquo;<samp>p</samp>&rsquo;</dt>
  204. <dd><p>Program precision. This option is the default and means a trap handler
  205. can only identify which program caused a floating-point exception.
  206. </p>
  207. </dd>
  208. <dt>&lsquo;<samp>f</samp>&rsquo;</dt>
  209. <dd><p>Function precision. The trap handler can determine the function that
  210. caused a floating-point exception.
  211. </p>
  212. </dd>
  213. <dt>&lsquo;<samp>i</samp>&rsquo;</dt>
  214. <dd><p>Instruction precision. The trap handler can determine the exact
  215. instruction that caused a floating-point exception.
  216. </p></dd>
  217. </dl>
  218. <p>Other Alpha compilers provide the equivalent options called
  219. <samp>-scope_safe</samp> and <samp>-resumption_safe</samp>.
  220. </p>
  221. </dd>
  222. <dt><code>-mieee-conformant</code></dt>
  223. <dd><a name="index-mieee_002dconformant"></a>
  224. <p>This option marks the generated code as IEEE conformant. You must not
  225. use this option unless you also specify <samp>-mtrap-precision=i</samp> and either
  226. <samp>-mfp-trap-mode=su</samp> or <samp>-mfp-trap-mode=sui</samp>. Its only effect
  227. is to emit the line &lsquo;<samp>.eflag 48</samp>&rsquo; in the function prologue of the
  228. generated assembly file.
  229. </p>
  230. </dd>
  231. <dt><code>-mbuild-constants</code></dt>
  232. <dd><a name="index-mbuild_002dconstants"></a>
  233. <p>Normally GCC examines a 32- or 64-bit integer constant to
  234. see if it can construct it from smaller constants in two or three
  235. instructions. If it cannot, it outputs the constant as a literal and
  236. generates code to load it from the data segment at run time.
  237. </p>
  238. <p>Use this option to require GCC to construct <em>all</em> integer constants
  239. using code, even if it takes more instructions (the maximum is six).
  240. </p>
  241. <p>You typically use this option to build a shared library dynamic
  242. loader. Itself a shared library, it must relocate itself in memory
  243. before it can find the variables and constants in its own data segment.
  244. </p>
  245. </dd>
  246. <dt><code>-mbwx</code></dt>
  247. <dt><code>-mno-bwx</code></dt>
  248. <dt><code>-mcix</code></dt>
  249. <dt><code>-mno-cix</code></dt>
  250. <dt><code>-mfix</code></dt>
  251. <dt><code>-mno-fix</code></dt>
  252. <dt><code>-mmax</code></dt>
  253. <dt><code>-mno-max</code></dt>
  254. <dd><a name="index-mbwx"></a>
  255. <a name="index-mno_002dbwx"></a>
  256. <a name="index-mcix"></a>
  257. <a name="index-mno_002dcix"></a>
  258. <a name="index-mfix"></a>
  259. <a name="index-mno_002dfix"></a>
  260. <a name="index-mmax"></a>
  261. <a name="index-mno_002dmax"></a>
  262. <p>Indicate whether GCC should generate code to use the optional BWX,
  263. CIX, FIX and MAX instruction sets. The default is to use the instruction
  264. sets supported by the CPU type specified via <samp>-mcpu=</samp> option or that
  265. of the CPU on which GCC was built if none is specified.
  266. </p>
  267. </dd>
  268. <dt><code>-mfloat-vax</code></dt>
  269. <dt><code>-mfloat-ieee</code></dt>
  270. <dd><a name="index-mfloat_002dvax"></a>
  271. <a name="index-mfloat_002dieee"></a>
  272. <p>Generate code that uses (does not use) VAX F and G floating-point
  273. arithmetic instead of IEEE single and double precision.
  274. </p>
  275. </dd>
  276. <dt><code>-mexplicit-relocs</code></dt>
  277. <dt><code>-mno-explicit-relocs</code></dt>
  278. <dd><a name="index-mexplicit_002drelocs"></a>
  279. <a name="index-mno_002dexplicit_002drelocs"></a>
  280. <p>Older Alpha assemblers provided no way to generate symbol relocations
  281. except via assembler macros. Use of these macros does not allow
  282. optimal instruction scheduling. GNU binutils as of version 2.12
  283. supports a new syntax that allows the compiler to explicitly mark
  284. which relocations should apply to which instructions. This option
  285. is mostly useful for debugging, as GCC detects the capabilities of
  286. the assembler when it is built and sets the default accordingly.
  287. </p>
  288. </dd>
  289. <dt><code>-msmall-data</code></dt>
  290. <dt><code>-mlarge-data</code></dt>
  291. <dd><a name="index-msmall_002ddata"></a>
  292. <a name="index-mlarge_002ddata"></a>
  293. <p>When <samp>-mexplicit-relocs</samp> is in effect, static data is
  294. accessed via <em>gp-relative</em> relocations. When <samp>-msmall-data</samp>
  295. is used, objects 8 bytes long or smaller are placed in a <em>small data area</em>
  296. (the <code>.sdata</code> and <code>.sbss</code> sections) and are accessed via
  297. 16-bit relocations off of the <code>$gp</code> register. This limits the
  298. size of the small data area to 64KB, but allows the variables to be
  299. directly accessed via a single instruction.
  300. </p>
  301. <p>The default is <samp>-mlarge-data</samp>. With this option the data area
  302. is limited to just below 2GB. Programs that require more than 2GB of
  303. data must use <code>malloc</code> or <code>mmap</code> to allocate the data in the
  304. heap instead of in the program&rsquo;s data segment.
  305. </p>
  306. <p>When generating code for shared libraries, <samp>-fpic</samp> implies
  307. <samp>-msmall-data</samp> and <samp>-fPIC</samp> implies <samp>-mlarge-data</samp>.
  308. </p>
  309. </dd>
  310. <dt><code>-msmall-text</code></dt>
  311. <dt><code>-mlarge-text</code></dt>
  312. <dd><a name="index-msmall_002dtext"></a>
  313. <a name="index-mlarge_002dtext"></a>
  314. <p>When <samp>-msmall-text</samp> is used, the compiler assumes that the
  315. code of the entire program (or shared library) fits in 4MB, and is
  316. thus reachable with a branch instruction. When <samp>-msmall-data</samp>
  317. is used, the compiler can assume that all local symbols share the
  318. same <code>$gp</code> value, and thus reduce the number of instructions
  319. required for a function call from 4 to 1.
  320. </p>
  321. <p>The default is <samp>-mlarge-text</samp>.
  322. </p>
  323. </dd>
  324. <dt><code>-mcpu=<var>cpu_type</var></code></dt>
  325. <dd><a name="index-mcpu-4"></a>
  326. <p>Set the instruction set and instruction scheduling parameters for
  327. machine type <var>cpu_type</var>. You can specify either the &lsquo;<samp>EV</samp>&rsquo;
  328. style name or the corresponding chip number. GCC supports scheduling
  329. parameters for the EV4, EV5 and EV6 family of processors and
  330. chooses the default values for the instruction set from the processor
  331. you specify. If you do not specify a processor type, GCC defaults
  332. to the processor on which the compiler was built.
  333. </p>
  334. <p>Supported values for <var>cpu_type</var> are
  335. </p>
  336. <dl compact="compact">
  337. <dt>&lsquo;<samp>ev4</samp>&rsquo;</dt>
  338. <dt>&lsquo;<samp>ev45</samp>&rsquo;</dt>
  339. <dt>&lsquo;<samp>21064</samp>&rsquo;</dt>
  340. <dd><p>Schedules as an EV4 and has no instruction set extensions.
  341. </p>
  342. </dd>
  343. <dt>&lsquo;<samp>ev5</samp>&rsquo;</dt>
  344. <dt>&lsquo;<samp>21164</samp>&rsquo;</dt>
  345. <dd><p>Schedules as an EV5 and has no instruction set extensions.
  346. </p>
  347. </dd>
  348. <dt>&lsquo;<samp>ev56</samp>&rsquo;</dt>
  349. <dt>&lsquo;<samp>21164a</samp>&rsquo;</dt>
  350. <dd><p>Schedules as an EV5 and supports the BWX extension.
  351. </p>
  352. </dd>
  353. <dt>&lsquo;<samp>pca56</samp>&rsquo;</dt>
  354. <dt>&lsquo;<samp>21164pc</samp>&rsquo;</dt>
  355. <dt>&lsquo;<samp>21164PC</samp>&rsquo;</dt>
  356. <dd><p>Schedules as an EV5 and supports the BWX and MAX extensions.
  357. </p>
  358. </dd>
  359. <dt>&lsquo;<samp>ev6</samp>&rsquo;</dt>
  360. <dt>&lsquo;<samp>21264</samp>&rsquo;</dt>
  361. <dd><p>Schedules as an EV6 and supports the BWX, FIX, and MAX extensions.
  362. </p>
  363. </dd>
  364. <dt>&lsquo;<samp>ev67</samp>&rsquo;</dt>
  365. <dt>&lsquo;<samp>21264a</samp>&rsquo;</dt>
  366. <dd><p>Schedules as an EV6 and supports the BWX, CIX, FIX, and MAX extensions.
  367. </p></dd>
  368. </dl>
  369. <p>Native toolchains also support the value &lsquo;<samp>native</samp>&rsquo;,
  370. which selects the best architecture option for the host processor.
  371. <samp>-mcpu=native</samp> has no effect if GCC does not recognize
  372. the processor.
  373. </p>
  374. </dd>
  375. <dt><code>-mtune=<var>cpu_type</var></code></dt>
  376. <dd><a name="index-mtune-6"></a>
  377. <p>Set only the instruction scheduling parameters for machine type
  378. <var>cpu_type</var>. The instruction set is not changed.
  379. </p>
  380. <p>Native toolchains also support the value &lsquo;<samp>native</samp>&rsquo;,
  381. which selects the best architecture option for the host processor.
  382. <samp>-mtune=native</samp> has no effect if GCC does not recognize
  383. the processor.
  384. </p>
  385. </dd>
  386. <dt><code>-mmemory-latency=<var>time</var></code></dt>
  387. <dd><a name="index-mmemory_002dlatency"></a>
  388. <p>Sets the latency the scheduler should assume for typical memory
  389. references as seen by the application. This number is highly
  390. dependent on the memory access patterns used by the application
  391. and the size of the external cache on the machine.
  392. </p>
  393. <p>Valid options for <var>time</var> are
  394. </p>
  395. <dl compact="compact">
  396. <dt>&lsquo;<samp><var>number</var></samp>&rsquo;</dt>
  397. <dd><p>A decimal number representing clock cycles.
  398. </p>
  399. </dd>
  400. <dt>&lsquo;<samp>L1</samp>&rsquo;</dt>
  401. <dt>&lsquo;<samp>L2</samp>&rsquo;</dt>
  402. <dt>&lsquo;<samp>L3</samp>&rsquo;</dt>
  403. <dt>&lsquo;<samp>main</samp>&rsquo;</dt>
  404. <dd><p>The compiler contains estimates of the number of clock cycles for
  405. &ldquo;typical&rdquo; EV4 &amp; EV5 hardware for the Level 1, 2 &amp; 3 caches
  406. (also called Dcache, Scache, and Bcache), as well as to main memory.
  407. Note that L3 is only valid for EV5.
  408. </p>
  409. </dd>
  410. </dl>
  411. </dd>
  412. </dl>
  413. <hr>
  414. <div class="header">
  415. <p>
  416. Next: <a href="eBPF-Options.html#eBPF-Options" accesskey="n" rel="next">eBPF Options</a>, Previous: <a href="Darwin-Options.html#Darwin-Options" accesskey="p" rel="prev">Darwin Options</a>, Up: <a href="Submodel-Options.html#Submodel-Options" accesskey="u" rel="up">Submodel Options</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Option-Index.html#Option-Index" title="Index" rel="index">Index</a>]</p>
  417. </div>
  418. </body>
  419. </html>