您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

SPARC-Options.html 24KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560
  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>SPARC Options (Using the GNU Compiler Collection (GCC))</title>
  21. <meta name="description" content="SPARC Options (Using the GNU Compiler Collection (GCC))">
  22. <meta name="keywords" content="SPARC 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="System-V-Options.html#System-V-Options" rel="next" title="System V Options">
  31. <link href="Solaris-2-Options.html#Solaris-2-Options" rel="prev" title="Solaris 2 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="SPARC-Options"></a>
  62. <div class="header">
  63. <p>
  64. Next: <a href="System-V-Options.html#System-V-Options" accesskey="n" rel="next">System V Options</a>, Previous: <a href="Solaris-2-Options.html#Solaris-2-Options" accesskey="p" rel="prev">Solaris 2 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="SPARC-Options-1"></a>
  68. <h4 class="subsection">3.19.50 SPARC Options</h4>
  69. <a name="index-SPARC-options"></a>
  70. <p>These &lsquo;<samp>-m</samp>&rsquo; options are supported on the SPARC:
  71. </p>
  72. <dl compact="compact">
  73. <dt><code>-mno-app-regs</code></dt>
  74. <dt><code>-mapp-regs</code></dt>
  75. <dd><a name="index-mno_002dapp_002dregs"></a>
  76. <a name="index-mapp_002dregs"></a>
  77. <p>Specify <samp>-mapp-regs</samp> to generate output using the global registers
  78. 2 through 4, which the SPARC SVR4 ABI reserves for applications. Like the
  79. global register 1, each global register 2 through 4 is then treated as an
  80. allocable register that is clobbered by function calls. This is the default.
  81. </p>
  82. <p>To be fully SVR4 ABI-compliant at the cost of some performance loss,
  83. specify <samp>-mno-app-regs</samp>. You should compile libraries and system
  84. software with this option.
  85. </p>
  86. </dd>
  87. <dt><code>-mflat</code></dt>
  88. <dt><code>-mno-flat</code></dt>
  89. <dd><a name="index-mflat"></a>
  90. <a name="index-mno_002dflat"></a>
  91. <p>With <samp>-mflat</samp>, the compiler does not generate save/restore instructions
  92. and uses a &ldquo;flat&rdquo; or single register window model. This model is compatible
  93. with the regular register window model. The local registers and the input
  94. registers (0&ndash;5) are still treated as &ldquo;call-saved&rdquo; registers and are
  95. saved on the stack as needed.
  96. </p>
  97. <p>With <samp>-mno-flat</samp> (the default), the compiler generates save/restore
  98. instructions (except for leaf functions). This is the normal operating mode.
  99. </p>
  100. </dd>
  101. <dt><code>-mfpu</code></dt>
  102. <dt><code>-mhard-float</code></dt>
  103. <dd><a name="index-mfpu-3"></a>
  104. <a name="index-mhard_002dfloat-8"></a>
  105. <p>Generate output containing floating-point instructions. This is the
  106. default.
  107. </p>
  108. </dd>
  109. <dt><code>-mno-fpu</code></dt>
  110. <dt><code>-msoft-float</code></dt>
  111. <dd><a name="index-mno_002dfpu"></a>
  112. <a name="index-msoft_002dfloat-12"></a>
  113. <p>Generate output containing library calls for floating point.
  114. <strong>Warning:</strong> the requisite libraries are not available for all SPARC
  115. targets. Normally the facilities of the machine&rsquo;s usual C compiler are
  116. used, but this cannot be done directly in cross-compilation. You must make
  117. your own arrangements to provide suitable library functions for
  118. cross-compilation. The embedded targets &lsquo;<samp>sparc-*-aout</samp>&rsquo; and
  119. &lsquo;<samp>sparclite-*-*</samp>&rsquo; do provide software floating-point support.
  120. </p>
  121. <p><samp>-msoft-float</samp> changes the calling convention in the output file;
  122. therefore, it is only useful if you compile <em>all</em> of a program with
  123. this option. In particular, you need to compile <samp>libgcc.a</samp>, the
  124. library that comes with GCC, with <samp>-msoft-float</samp> in order for
  125. this to work.
  126. </p>
  127. </dd>
  128. <dt><code>-mhard-quad-float</code></dt>
  129. <dd><a name="index-mhard_002dquad_002dfloat"></a>
  130. <p>Generate output containing quad-word (long double) floating-point
  131. instructions.
  132. </p>
  133. </dd>
  134. <dt><code>-msoft-quad-float</code></dt>
  135. <dd><a name="index-msoft_002dquad_002dfloat"></a>
  136. <p>Generate output containing library calls for quad-word (long double)
  137. floating-point instructions. The functions called are those specified
  138. in the SPARC ABI. This is the default.
  139. </p>
  140. <p>As of this writing, there are no SPARC implementations that have hardware
  141. support for the quad-word floating-point instructions. They all invoke
  142. a trap handler for one of these instructions, and then the trap handler
  143. emulates the effect of the instruction. Because of the trap handler overhead,
  144. this is much slower than calling the ABI library routines. Thus the
  145. <samp>-msoft-quad-float</samp> option is the default.
  146. </p>
  147. </dd>
  148. <dt><code>-mno-unaligned-doubles</code></dt>
  149. <dt><code>-munaligned-doubles</code></dt>
  150. <dd><a name="index-mno_002dunaligned_002ddoubles"></a>
  151. <a name="index-munaligned_002ddoubles"></a>
  152. <p>Assume that doubles have 8-byte alignment. This is the default.
  153. </p>
  154. <p>With <samp>-munaligned-doubles</samp>, GCC assumes that doubles have 8-byte
  155. alignment only if they are contained in another type, or if they have an
  156. absolute address. Otherwise, it assumes they have 4-byte alignment.
  157. Specifying this option avoids some rare compatibility problems with code
  158. generated by other compilers. It is not the default because it results
  159. in a performance loss, especially for floating-point code.
  160. </p>
  161. </dd>
  162. <dt><code>-muser-mode</code></dt>
  163. <dt><code>-mno-user-mode</code></dt>
  164. <dd><a name="index-muser_002dmode"></a>
  165. <a name="index-mno_002duser_002dmode"></a>
  166. <p>Do not generate code that can only run in supervisor mode. This is relevant
  167. only for the <code>casa</code> instruction emitted for the LEON3 processor. This
  168. is the default.
  169. </p>
  170. </dd>
  171. <dt><code>-mfaster-structs</code></dt>
  172. <dt><code>-mno-faster-structs</code></dt>
  173. <dd><a name="index-mfaster_002dstructs"></a>
  174. <a name="index-mno_002dfaster_002dstructs"></a>
  175. <p>With <samp>-mfaster-structs</samp>, the compiler assumes that structures
  176. should have 8-byte alignment. This enables the use of pairs of
  177. <code>ldd</code> and <code>std</code> instructions for copies in structure
  178. assignment, in place of twice as many <code>ld</code> and <code>st</code> pairs.
  179. However, the use of this changed alignment directly violates the SPARC
  180. ABI. Thus, it&rsquo;s intended only for use on targets where the developer
  181. acknowledges that their resulting code is not directly in line with
  182. the rules of the ABI.
  183. </p>
  184. </dd>
  185. <dt><code>-mstd-struct-return</code></dt>
  186. <dt><code>-mno-std-struct-return</code></dt>
  187. <dd><a name="index-mstd_002dstruct_002dreturn"></a>
  188. <a name="index-mno_002dstd_002dstruct_002dreturn"></a>
  189. <p>With <samp>-mstd-struct-return</samp>, the compiler generates checking code
  190. in functions returning structures or unions to detect size mismatches
  191. between the two sides of function calls, as per the 32-bit ABI.
  192. </p>
  193. <p>The default is <samp>-mno-std-struct-return</samp>. This option has no effect
  194. in 64-bit mode.
  195. </p>
  196. </dd>
  197. <dt><code>-mlra</code></dt>
  198. <dt><code>-mno-lra</code></dt>
  199. <dd><a name="index-mlra-3"></a>
  200. <a name="index-mno_002dlra"></a>
  201. <p>Enable Local Register Allocation. This is the default for SPARC since GCC 7
  202. so <samp>-mno-lra</samp> needs to be passed to get old Reload.
  203. </p>
  204. </dd>
  205. <dt><code>-mcpu=<var>cpu_type</var></code></dt>
  206. <dd><a name="index-mcpu-11"></a>
  207. <p>Set the instruction set, register set, and instruction scheduling parameters
  208. for machine type <var>cpu_type</var>. Supported values for <var>cpu_type</var> are
  209. &lsquo;<samp>v7</samp>&rsquo;, &lsquo;<samp>cypress</samp>&rsquo;, &lsquo;<samp>v8</samp>&rsquo;, &lsquo;<samp>supersparc</samp>&rsquo;, &lsquo;<samp>hypersparc</samp>&rsquo;,
  210. &lsquo;<samp>leon</samp>&rsquo;, &lsquo;<samp>leon3</samp>&rsquo;, &lsquo;<samp>leon3v7</samp>&rsquo;, &lsquo;<samp>sparclite</samp>&rsquo;, &lsquo;<samp>f930</samp>&rsquo;,
  211. &lsquo;<samp>f934</samp>&rsquo;, &lsquo;<samp>sparclite86x</samp>&rsquo;, &lsquo;<samp>sparclet</samp>&rsquo;, &lsquo;<samp>tsc701</samp>&rsquo;, &lsquo;<samp>v9</samp>&rsquo;,
  212. &lsquo;<samp>ultrasparc</samp>&rsquo;, &lsquo;<samp>ultrasparc3</samp>&rsquo;, &lsquo;<samp>niagara</samp>&rsquo;, &lsquo;<samp>niagara2</samp>&rsquo;,
  213. &lsquo;<samp>niagara3</samp>&rsquo;, &lsquo;<samp>niagara4</samp>&rsquo;, &lsquo;<samp>niagara7</samp>&rsquo; and &lsquo;<samp>m8</samp>&rsquo;.
  214. </p>
  215. <p>Native Solaris and GNU/Linux toolchains also support the value &lsquo;<samp>native</samp>&rsquo;,
  216. which selects the best architecture option for the host processor.
  217. <samp>-mcpu=native</samp> has no effect if GCC does not recognize
  218. the processor.
  219. </p>
  220. <p>Default instruction scheduling parameters are used for values that select
  221. an architecture and not an implementation. These are &lsquo;<samp>v7</samp>&rsquo;, &lsquo;<samp>v8</samp>&rsquo;,
  222. &lsquo;<samp>sparclite</samp>&rsquo;, &lsquo;<samp>sparclet</samp>&rsquo;, &lsquo;<samp>v9</samp>&rsquo;.
  223. </p>
  224. <p>Here is a list of each supported architecture and their supported
  225. implementations.
  226. </p>
  227. <dl compact="compact">
  228. <dt>v7</dt>
  229. <dd><p>cypress, leon3v7
  230. </p>
  231. </dd>
  232. <dt>v8</dt>
  233. <dd><p>supersparc, hypersparc, leon, leon3
  234. </p>
  235. </dd>
  236. <dt>sparclite</dt>
  237. <dd><p>f930, f934, sparclite86x
  238. </p>
  239. </dd>
  240. <dt>sparclet</dt>
  241. <dd><p>tsc701
  242. </p>
  243. </dd>
  244. <dt>v9</dt>
  245. <dd><p>ultrasparc, ultrasparc3, niagara, niagara2, niagara3, niagara4,
  246. niagara7, m8
  247. </p></dd>
  248. </dl>
  249. <p>By default (unless configured otherwise), GCC generates code for the V7
  250. variant of the SPARC architecture. With <samp>-mcpu=cypress</samp>, the compiler
  251. additionally optimizes it for the Cypress CY7C602 chip, as used in the
  252. SPARCStation/SPARCServer 3xx series. This is also appropriate for the older
  253. SPARCStation 1, 2, IPX etc.
  254. </p>
  255. <p>With <samp>-mcpu=v8</samp>, GCC generates code for the V8 variant of the SPARC
  256. architecture. The only difference from V7 code is that the compiler emits
  257. the integer multiply and integer divide instructions which exist in SPARC-V8
  258. but not in SPARC-V7. With <samp>-mcpu=supersparc</samp>, the compiler additionally
  259. optimizes it for the SuperSPARC chip, as used in the SPARCStation 10, 1000 and
  260. 2000 series.
  261. </p>
  262. <p>With <samp>-mcpu=sparclite</samp>, GCC generates code for the SPARClite variant of
  263. the SPARC architecture. This adds the integer multiply, integer divide step
  264. and scan (<code>ffs</code>) instructions which exist in SPARClite but not in SPARC-V7.
  265. With <samp>-mcpu=f930</samp>, the compiler additionally optimizes it for the
  266. Fujitsu MB86930 chip, which is the original SPARClite, with no FPU. With
  267. <samp>-mcpu=f934</samp>, the compiler additionally optimizes it for the Fujitsu
  268. MB86934 chip, which is the more recent SPARClite with FPU.
  269. </p>
  270. <p>With <samp>-mcpu=sparclet</samp>, GCC generates code for the SPARClet variant of
  271. the SPARC architecture. This adds the integer multiply, multiply/accumulate,
  272. integer divide step and scan (<code>ffs</code>) instructions which exist in SPARClet
  273. but not in SPARC-V7. With <samp>-mcpu=tsc701</samp>, the compiler additionally
  274. optimizes it for the TEMIC SPARClet chip.
  275. </p>
  276. <p>With <samp>-mcpu=v9</samp>, GCC generates code for the V9 variant of the SPARC
  277. architecture. This adds 64-bit integer and floating-point move instructions,
  278. 3 additional floating-point condition code registers and conditional move
  279. instructions. With <samp>-mcpu=ultrasparc</samp>, the compiler additionally
  280. optimizes it for the Sun UltraSPARC I/II/IIi chips. With
  281. <samp>-mcpu=ultrasparc3</samp>, the compiler additionally optimizes it for the
  282. Sun UltraSPARC III/III+/IIIi/IIIi+/IV/IV+ chips. With
  283. <samp>-mcpu=niagara</samp>, the compiler additionally optimizes it for
  284. Sun UltraSPARC T1 chips. With <samp>-mcpu=niagara2</samp>, the compiler
  285. additionally optimizes it for Sun UltraSPARC T2 chips. With
  286. <samp>-mcpu=niagara3</samp>, the compiler additionally optimizes it for Sun
  287. UltraSPARC T3 chips. With <samp>-mcpu=niagara4</samp>, the compiler
  288. additionally optimizes it for Sun UltraSPARC T4 chips. With
  289. <samp>-mcpu=niagara7</samp>, the compiler additionally optimizes it for
  290. Oracle SPARC M7 chips. With <samp>-mcpu=m8</samp>, the compiler
  291. additionally optimizes it for Oracle M8 chips.
  292. </p>
  293. </dd>
  294. <dt><code>-mtune=<var>cpu_type</var></code></dt>
  295. <dd><a name="index-mtune-14"></a>
  296. <p>Set the instruction scheduling parameters for machine type
  297. <var>cpu_type</var>, but do not set the instruction set or register set that the
  298. option <samp>-mcpu=<var>cpu_type</var></samp> does.
  299. </p>
  300. <p>The same values for <samp>-mcpu=<var>cpu_type</var></samp> can be used for
  301. <samp>-mtune=<var>cpu_type</var></samp>, but the only useful values are those
  302. that select a particular CPU implementation. Those are
  303. &lsquo;<samp>cypress</samp>&rsquo;, &lsquo;<samp>supersparc</samp>&rsquo;, &lsquo;<samp>hypersparc</samp>&rsquo;, &lsquo;<samp>leon</samp>&rsquo;,
  304. &lsquo;<samp>leon3</samp>&rsquo;, &lsquo;<samp>leon3v7</samp>&rsquo;, &lsquo;<samp>f930</samp>&rsquo;, &lsquo;<samp>f934</samp>&rsquo;,
  305. &lsquo;<samp>sparclite86x</samp>&rsquo;, &lsquo;<samp>tsc701</samp>&rsquo;, &lsquo;<samp>ultrasparc</samp>&rsquo;,
  306. &lsquo;<samp>ultrasparc3</samp>&rsquo;, &lsquo;<samp>niagara</samp>&rsquo;, &lsquo;<samp>niagara2</samp>&rsquo;, &lsquo;<samp>niagara3</samp>&rsquo;,
  307. &lsquo;<samp>niagara4</samp>&rsquo;, &lsquo;<samp>niagara7</samp>&rsquo; and &lsquo;<samp>m8</samp>&rsquo;. With native Solaris
  308. and GNU/Linux toolchains, &lsquo;<samp>native</samp>&rsquo; can also be used.
  309. </p>
  310. </dd>
  311. <dt><code>-mv8plus</code></dt>
  312. <dt><code>-mno-v8plus</code></dt>
  313. <dd><a name="index-mv8plus"></a>
  314. <a name="index-mno_002dv8plus"></a>
  315. <p>With <samp>-mv8plus</samp>, GCC generates code for the SPARC-V8+ ABI. The
  316. difference from the V8 ABI is that the global and out registers are
  317. considered 64 bits wide. This is enabled by default on Solaris in 32-bit
  318. mode for all SPARC-V9 processors.
  319. </p>
  320. </dd>
  321. <dt><code>-mvis</code></dt>
  322. <dt><code>-mno-vis</code></dt>
  323. <dd><a name="index-mvis"></a>
  324. <a name="index-mno_002dvis"></a>
  325. <p>With <samp>-mvis</samp>, GCC generates code that takes advantage of the UltraSPARC
  326. Visual Instruction Set extensions. The default is <samp>-mno-vis</samp>.
  327. </p>
  328. </dd>
  329. <dt><code>-mvis2</code></dt>
  330. <dt><code>-mno-vis2</code></dt>
  331. <dd><a name="index-mvis2"></a>
  332. <a name="index-mno_002dvis2"></a>
  333. <p>With <samp>-mvis2</samp>, GCC generates code that takes advantage of
  334. version 2.0 of the UltraSPARC Visual Instruction Set extensions. The
  335. default is <samp>-mvis2</samp> when targeting a cpu that supports such
  336. instructions, such as UltraSPARC-III and later. Setting <samp>-mvis2</samp>
  337. also sets <samp>-mvis</samp>.
  338. </p>
  339. </dd>
  340. <dt><code>-mvis3</code></dt>
  341. <dt><code>-mno-vis3</code></dt>
  342. <dd><a name="index-mvis3"></a>
  343. <a name="index-mno_002dvis3"></a>
  344. <p>With <samp>-mvis3</samp>, GCC generates code that takes advantage of
  345. version 3.0 of the UltraSPARC Visual Instruction Set extensions. The
  346. default is <samp>-mvis3</samp> when targeting a cpu that supports such
  347. instructions, such as niagara-3 and later. Setting <samp>-mvis3</samp>
  348. also sets <samp>-mvis2</samp> and <samp>-mvis</samp>.
  349. </p>
  350. </dd>
  351. <dt><code>-mvis4</code></dt>
  352. <dt><code>-mno-vis4</code></dt>
  353. <dd><a name="index-mvis4"></a>
  354. <a name="index-mno_002dvis4"></a>
  355. <p>With <samp>-mvis4</samp>, GCC generates code that takes advantage of
  356. version 4.0 of the UltraSPARC Visual Instruction Set extensions. The
  357. default is <samp>-mvis4</samp> when targeting a cpu that supports such
  358. instructions, such as niagara-7 and later. Setting <samp>-mvis4</samp>
  359. also sets <samp>-mvis3</samp>, <samp>-mvis2</samp> and <samp>-mvis</samp>.
  360. </p>
  361. </dd>
  362. <dt><code>-mvis4b</code></dt>
  363. <dt><code>-mno-vis4b</code></dt>
  364. <dd><a name="index-mvis4b"></a>
  365. <a name="index-mno_002dvis4b"></a>
  366. <p>With <samp>-mvis4b</samp>, GCC generates code that takes advantage of
  367. version 4.0 of the UltraSPARC Visual Instruction Set extensions, plus
  368. the additional VIS instructions introduced in the Oracle SPARC
  369. Architecture 2017. The default is <samp>-mvis4b</samp> when targeting a
  370. cpu that supports such instructions, such as m8 and later. Setting
  371. <samp>-mvis4b</samp> also sets <samp>-mvis4</samp>, <samp>-mvis3</samp>,
  372. <samp>-mvis2</samp> and <samp>-mvis</samp>.
  373. </p>
  374. </dd>
  375. <dt><code>-mcbcond</code></dt>
  376. <dt><code>-mno-cbcond</code></dt>
  377. <dd><a name="index-mcbcond"></a>
  378. <a name="index-mno_002dcbcond"></a>
  379. <p>With <samp>-mcbcond</samp>, GCC generates code that takes advantage of the UltraSPARC
  380. Compare-and-Branch-on-Condition instructions. The default is <samp>-mcbcond</samp>
  381. when targeting a CPU that supports such instructions, such as Niagara-4 and
  382. later.
  383. </p>
  384. </dd>
  385. <dt><code>-mfmaf</code></dt>
  386. <dt><code>-mno-fmaf</code></dt>
  387. <dd><a name="index-mfmaf"></a>
  388. <a name="index-mno_002dfmaf"></a>
  389. <p>With <samp>-mfmaf</samp>, GCC generates code that takes advantage of the UltraSPARC
  390. Fused Multiply-Add Floating-point instructions. The default is <samp>-mfmaf</samp>
  391. when targeting a CPU that supports such instructions, such as Niagara-3 and
  392. later.
  393. </p>
  394. </dd>
  395. <dt><code>-mfsmuld</code></dt>
  396. <dt><code>-mno-fsmuld</code></dt>
  397. <dd><a name="index-mfsmuld"></a>
  398. <a name="index-mno_002dfsmuld"></a>
  399. <p>With <samp>-mfsmuld</samp>, GCC generates code that takes advantage of the
  400. Floating-point Multiply Single to Double (FsMULd) instruction. The default is
  401. <samp>-mfsmuld</samp> when targeting a CPU supporting the architecture versions V8
  402. or V9 with FPU except <samp>-mcpu=leon</samp>.
  403. </p>
  404. </dd>
  405. <dt><code>-mpopc</code></dt>
  406. <dt><code>-mno-popc</code></dt>
  407. <dd><a name="index-mpopc"></a>
  408. <a name="index-mno_002dpopc"></a>
  409. <p>With <samp>-mpopc</samp>, GCC generates code that takes advantage of the UltraSPARC
  410. Population Count instruction. The default is <samp>-mpopc</samp>
  411. when targeting a CPU that supports such an instruction, such as Niagara-2 and
  412. later.
  413. </p>
  414. </dd>
  415. <dt><code>-msubxc</code></dt>
  416. <dt><code>-mno-subxc</code></dt>
  417. <dd><a name="index-msubxc"></a>
  418. <a name="index-mno_002dsubxc"></a>
  419. <p>With <samp>-msubxc</samp>, GCC generates code that takes advantage of the UltraSPARC
  420. Subtract-Extended-with-Carry instruction. The default is <samp>-msubxc</samp>
  421. when targeting a CPU that supports such an instruction, such as Niagara-7 and
  422. later.
  423. </p>
  424. </dd>
  425. <dt><code>-mfix-at697f</code></dt>
  426. <dd><a name="index-mfix_002dat697f"></a>
  427. <p>Enable the documented workaround for the single erratum of the Atmel AT697F
  428. processor (which corresponds to erratum #13 of the AT697E processor).
  429. </p>
  430. </dd>
  431. <dt><code>-mfix-ut699</code></dt>
  432. <dd><a name="index-mfix_002dut699"></a>
  433. <p>Enable the documented workarounds for the floating-point errata and the data
  434. cache nullify errata of the UT699 processor.
  435. </p>
  436. </dd>
  437. <dt><code>-mfix-ut700</code></dt>
  438. <dd><a name="index-mfix_002dut700"></a>
  439. <p>Enable the documented workaround for the back-to-back store errata of
  440. the UT699E/UT700 processor.
  441. </p>
  442. </dd>
  443. <dt><code>-mfix-gr712rc</code></dt>
  444. <dd><a name="index-mfix_002dgr712rc"></a>
  445. <p>Enable the documented workaround for the back-to-back store errata of
  446. the GR712RC processor.
  447. </p></dd>
  448. </dl>
  449. <p>These &lsquo;<samp>-m</samp>&rsquo; options are supported in addition to the above
  450. on SPARC-V9 processors in 64-bit environments:
  451. </p>
  452. <dl compact="compact">
  453. <dt><code>-m32</code></dt>
  454. <dt><code>-m64</code></dt>
  455. <dd><a name="index-m32-2"></a>
  456. <a name="index-m64-3"></a>
  457. <p>Generate code for a 32-bit or 64-bit environment.
  458. The 32-bit environment sets int, long and pointer to 32 bits.
  459. The 64-bit environment sets int to 32 bits and long and pointer
  460. to 64 bits.
  461. </p>
  462. </dd>
  463. <dt><code>-mcmodel=<var>which</var></code></dt>
  464. <dd><a name="index-mcmodel-1"></a>
  465. <p>Set the code model to one of
  466. </p>
  467. <dl compact="compact">
  468. <dt>&lsquo;<samp>medlow</samp>&rsquo;</dt>
  469. <dd><p>The Medium/Low code model: 64-bit addresses, programs
  470. must be linked in the low 32 bits of memory. Programs can be statically
  471. or dynamically linked.
  472. </p>
  473. </dd>
  474. <dt>&lsquo;<samp>medmid</samp>&rsquo;</dt>
  475. <dd><p>The Medium/Middle code model: 64-bit addresses, programs
  476. must be linked in the low 44 bits of memory, the text and data segments must
  477. be less than 2GB in size and the data segment must be located within 2GB of
  478. the text segment.
  479. </p>
  480. </dd>
  481. <dt>&lsquo;<samp>medany</samp>&rsquo;</dt>
  482. <dd><p>The Medium/Anywhere code model: 64-bit addresses, programs
  483. may be linked anywhere in memory, the text and data segments must be less
  484. than 2GB in size and the data segment must be located within 2GB of the
  485. text segment.
  486. </p>
  487. </dd>
  488. <dt>&lsquo;<samp>embmedany</samp>&rsquo;</dt>
  489. <dd><p>The Medium/Anywhere code model for embedded systems:
  490. 64-bit addresses, the text and data segments must be less than 2GB in
  491. size, both starting anywhere in memory (determined at link time). The
  492. global register %g4 points to the base of the data segment. Programs
  493. are statically linked and PIC is not supported.
  494. </p></dd>
  495. </dl>
  496. </dd>
  497. <dt><code>-mmemory-model=<var>mem-model</var></code></dt>
  498. <dd><a name="index-mmemory_002dmodel"></a>
  499. <p>Set the memory model in force on the processor to one of
  500. </p>
  501. <dl compact="compact">
  502. <dt>&lsquo;<samp>default</samp>&rsquo;</dt>
  503. <dd><p>The default memory model for the processor and operating system.
  504. </p>
  505. </dd>
  506. <dt>&lsquo;<samp>rmo</samp>&rsquo;</dt>
  507. <dd><p>Relaxed Memory Order
  508. </p>
  509. </dd>
  510. <dt>&lsquo;<samp>pso</samp>&rsquo;</dt>
  511. <dd><p>Partial Store Order
  512. </p>
  513. </dd>
  514. <dt>&lsquo;<samp>tso</samp>&rsquo;</dt>
  515. <dd><p>Total Store Order
  516. </p>
  517. </dd>
  518. <dt>&lsquo;<samp>sc</samp>&rsquo;</dt>
  519. <dd><p>Sequential Consistency
  520. </p></dd>
  521. </dl>
  522. <p>These memory models are formally defined in Appendix D of the SPARC-V9
  523. architecture manual, as set in the processor&rsquo;s <code>PSTATE.MM</code> field.
  524. </p>
  525. </dd>
  526. <dt><code>-mstack-bias</code></dt>
  527. <dt><code>-mno-stack-bias</code></dt>
  528. <dd><a name="index-mstack_002dbias"></a>
  529. <a name="index-mno_002dstack_002dbias"></a>
  530. <p>With <samp>-mstack-bias</samp>, GCC assumes that the stack pointer, and
  531. frame pointer if present, are offset by -2047 which must be added back
  532. when making stack frame references. This is the default in 64-bit mode.
  533. Otherwise, assume no such offset is present.
  534. </p></dd>
  535. </dl>
  536. <hr>
  537. <div class="header">
  538. <p>
  539. Next: <a href="System-V-Options.html#System-V-Options" accesskey="n" rel="next">System V Options</a>, Previous: <a href="Solaris-2-Options.html#Solaris-2-Options" accesskey="p" rel="prev">Solaris 2 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>
  540. </div>
  541. </body>
  542. </html>