]>
Commit | Line | Data |
---|---|---|
c63539ff ML |
1 | .. |
2 | Copyright 1988-2022 Free Software Foundation, Inc. | |
3 | This is part of the GCC manual. | |
4 | For copying conditions, see the copyright.rst file. | |
5 | ||
6 | .. program:: V850 | |
7 | ||
8 | .. index:: V850 Options | |
9 | ||
10 | .. _v850-options: | |
11 | ||
12 | V850 Options | |
13 | ^^^^^^^^^^^^ | |
14 | ||
15 | These :samp:`-m` options are defined for V850 implementations: | |
16 | ||
17 | .. option:: -mlong-calls, -mno-long-calls | |
18 | ||
19 | Treat all calls as being far away (near). If calls are assumed to be | |
20 | far away, the compiler always loads the function's address into a | |
21 | register, and calls indirect through the pointer. | |
22 | ||
23 | .. option:: -mno-ep, -mep | |
24 | ||
25 | Do not optimize (do optimize) basic blocks that use the same index | |
26 | pointer 4 or more times to copy pointer into the ``ep`` register, and | |
27 | use the shorter ``sld`` and ``sst`` instructions. The :option:`-mep` | |
28 | option is on by default if you optimize. | |
29 | ||
30 | .. option:: -mno-prolog-function, -mprolog-function | |
31 | ||
32 | Do not use (do use) external functions to save and restore registers | |
33 | at the prologue and epilogue of a function. The external functions | |
34 | are slower, but use less code space if more than one function saves | |
35 | the same number of registers. The :option:`-mprolog-function` option | |
36 | is on by default if you optimize. | |
37 | ||
38 | .. option:: -mspace | |
39 | ||
40 | Try to make the code as small as possible. At present, this just turns | |
41 | on the :option:`-mep` and :option:`-mprolog-function` options. | |
42 | ||
43 | .. option:: -mtda={n} | |
44 | ||
45 | Put static or global variables whose size is :samp:`{n}` bytes or less into | |
46 | the tiny data area that register ``ep`` points to. The tiny data | |
47 | area can hold up to 256 bytes in total (128 bytes for byte references). | |
48 | ||
49 | .. option:: -msda={n} | |
50 | ||
51 | Put static or global variables whose size is :samp:`{n}` bytes or less into | |
52 | the small data area that register ``gp`` points to. The small data | |
53 | area can hold up to 64 kilobytes. | |
54 | ||
55 | .. option:: -mzda={n} | |
56 | ||
57 | Put static or global variables whose size is :samp:`{n}` bytes or less into | |
58 | the first 32 kilobytes of memory. | |
59 | ||
60 | .. option:: -mv850 | |
61 | ||
62 | Specify that the target processor is the V850. | |
63 | ||
64 | .. option:: -mv850e3v5 | |
65 | ||
66 | Specify that the target processor is the V850E3V5. The preprocessor | |
67 | constant ``__v850e3v5__`` is defined if this option is used. | |
68 | ||
69 | .. option:: -mv850e2v4 | |
70 | ||
71 | Specify that the target processor is the V850E3V5. This is an alias for | |
72 | the :option:`-mv850e3v5` option. | |
73 | ||
74 | .. option:: -mv850e2v3 | |
75 | ||
76 | Specify that the target processor is the V850E2V3. The preprocessor | |
77 | constant ``__v850e2v3__`` is defined if this option is used. | |
78 | ||
79 | .. option:: -mv850e2 | |
80 | ||
81 | Specify that the target processor is the V850E2. The preprocessor | |
82 | constant ``__v850e2__`` is defined if this option is used. | |
83 | ||
84 | .. option:: -mv850e1 | |
85 | ||
86 | Specify that the target processor is the V850E1. The preprocessor | |
87 | constants ``__v850e1__`` and ``__v850e__`` are defined if | |
88 | this option is used. | |
89 | ||
90 | .. option:: -mv850es | |
91 | ||
92 | Specify that the target processor is the V850ES. This is an alias for | |
93 | the :option:`-mv850e1` option. | |
94 | ||
95 | .. option:: -mv850e | |
96 | ||
97 | Specify that the target processor is the V850E. The preprocessor | |
98 | constant ``__v850e__`` is defined if this option is used. | |
99 | ||
100 | If neither :option:`-mv850` nor :option:`-mv850e` nor :option:`-mv850e1` | |
101 | nor :option:`-mv850e2` nor :option:`-mv850e2v3` nor :option:`-mv850e3v5` | |
102 | are defined then a default target processor is chosen and the | |
103 | relevant :samp:`__v850*__` preprocessor constant is defined. | |
104 | ||
105 | The preprocessor constants ``__v850`` and ``__v851__`` are always | |
106 | defined, regardless of which processor variant is the target. | |
107 | ||
108 | .. option:: -mdisable-callt, -mno-disable-callt | |
109 | ||
110 | This option suppresses generation of the ``CALLT`` instruction for the | |
111 | v850e, v850e1, v850e2, v850e2v3 and v850e3v5 flavors of the v850 | |
112 | architecture. | |
113 | ||
114 | This option is enabled by default when the RH850 ABI is | |
115 | in use (see :option:`-mrh850-abi`), and disabled by default when the | |
116 | GCC ABI is in use. If ``CALLT`` instructions are being generated | |
117 | then the C preprocessor symbol ``__V850_CALLT__`` is defined. | |
118 | ||
119 | .. option:: -mrelax, -mno-relax | |
120 | ||
121 | Pass on (or do not pass on) the :option:`-mrelax` command-line option | |
122 | to the assembler. | |
123 | ||
124 | .. option:: -mlong-jumps, -mno-long-jumps | |
125 | ||
126 | Disable (or re-enable) the generation of PC-relative jump instructions. | |
127 | ||
128 | .. option:: -msoft-float, -mhard-float | |
129 | ||
130 | Disable (or re-enable) the generation of hardware floating point | |
131 | instructions. This option is only significant when the target | |
132 | architecture is :samp:`V850E2V3` or higher. If hardware floating point | |
133 | instructions are being generated then the C preprocessor symbol | |
134 | ``__FPU_OK__`` is defined, otherwise the symbol | |
135 | ``__NO_FPU__`` is defined. | |
136 | ||
137 | .. option:: -mloop | |
138 | ||
139 | Enables the use of the e3v5 LOOP instruction. The use of this | |
140 | instruction is not enabled by default when the e3v5 architecture is | |
141 | selected because its use is still experimental. | |
142 | ||
143 | .. option:: -mrh850-abi, -mghs | |
144 | ||
145 | Enables support for the RH850 version of the V850 ABI. This is the | |
146 | default. With this version of the ABI the following rules apply: | |
147 | ||
148 | * Integer sized structures and unions are returned via a memory pointer | |
149 | rather than a register. | |
150 | ||
151 | * Large structures and unions (more than 8 bytes in size) are passed by | |
152 | value. | |
153 | ||
154 | * Functions are aligned to 16-bit boundaries. | |
155 | ||
156 | * The :option:`-m8byte-align` command-line option is supported. | |
157 | ||
158 | * The :option:`-mdisable-callt` command-line option is enabled by | |
159 | default. The :option:`-mno-disable-callt` command-line option is not | |
160 | supported. | |
161 | ||
162 | When this version of the ABI is enabled the C preprocessor symbol | |
163 | ``__V850_RH850_ABI__`` is defined. | |
164 | ||
165 | .. option:: -mgcc-abi | |
166 | ||
167 | Enables support for the old GCC version of the V850 ABI. With this | |
168 | version of the ABI the following rules apply: | |
169 | ||
170 | * Integer sized structures and unions are returned in register ``r10``. | |
171 | ||
172 | * Large structures and unions (more than 8 bytes in size) are passed by | |
173 | reference. | |
174 | ||
175 | * Functions are aligned to 32-bit boundaries, unless optimizing for | |
176 | size. | |
177 | ||
178 | * The :option:`-m8byte-align` command-line option is not supported. | |
179 | ||
180 | * The :option:`-mdisable-callt` command-line option is supported but not | |
181 | enabled by default. | |
182 | ||
183 | When this version of the ABI is enabled the C preprocessor symbol | |
184 | ``__V850_GCC_ABI__`` is defined. | |
185 | ||
186 | .. option:: -m8byte-align, -mno-8byte-align | |
187 | ||
188 | Enables support for ``double`` and ``long long`` types to be | |
189 | aligned on 8-byte boundaries. The default is to restrict the | |
190 | alignment of all objects to at most 4-bytes. When | |
191 | :option:`-m8byte-align` is in effect the C preprocessor symbol | |
192 | ``__V850_8BYTE_ALIGN__`` is defined. | |
193 | ||
194 | .. option:: -mbig-switch | |
195 | ||
196 | Generate code suitable for big switch tables. Use this option only if | |
197 | the assembler/linker complain about out of range branches within a switch | |
198 | table. | |
199 | ||
200 | .. option:: -mapp-regs | |
201 | ||
202 | This option causes r2 and r5 to be used in the code generated by | |
203 | the compiler. This setting is the default. | |
204 | ||
205 | .. option:: -mno-app-regs | |
206 | ||
3ed1b4ce | 207 | This option causes r2 and r5 to be treated as fixed registers. |