1; Options for the S/390 / zSeries port of the compiler.
2
3; Copyright (C) 2005-2020 Free Software Foundation, Inc.
4;
5; This file is part of GCC.
6;
7; GCC is free software; you can redistribute it and/or modify it under
8; the terms of the GNU General Public License as published by the Free
9; Software Foundation; either version 3, or (at your option) any later
10; version.
11;
12; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
13; WARRANTY; without even the implied warranty of MERCHANTABILITY or
14; FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
15; for more details.
16;
17; You should have received a copy of the GNU General Public License
18; along with GCC; see the file COPYING3.  If not see
19; <http://www.gnu.org/licenses/>.
20
21HeaderInclude
22config/s390/s390-opts.h
23
24;; Definitions to add to the cl_target_option and gcc_options structures
25
26;; whether -march was specified
27TargetVariable
28unsigned char s390_arch_specified
29
30;; Flags derived from s390_arch
31TargetVariable
32int s390_arch_flags
33
34;; whether -mtune was specified
35TargetVariable
36unsigned char s390_tune_specified
37
38;; Flags derived from s390_tune
39TargetVariable
40int s390_tune_flags
41
42;; Cpu cost table (this is actually a "const struct processor_cost *")
43Variable
44long s390_cost_pointer
45
46m31
47Target Report RejectNegative Negative(m64) InverseMask(64BIT)
4831 bit ABI.
49
50m64
51Target Report RejectNegative Negative(m31) Mask(64BIT)
5264 bit ABI.
53
54march=
55Target RejectNegative Joined Enum(processor_type) Var(s390_arch) Init(PROCESSOR_max) Save
56Generate code for given CPU.
57
58Enum
59Name(processor_type) Type(enum processor_type)
60
61EnumValue
62Enum(processor_type) String(z900) Value(PROCESSOR_2064_Z900)
63
64EnumValue
65Enum(processor_type) String(arch5) Value(PROCESSOR_2064_Z900)
66
67EnumValue
68Enum(processor_type) String(z990) Value(PROCESSOR_2084_Z990)
69
70EnumValue
71Enum(processor_type) String(arch6) Value(PROCESSOR_2084_Z990)
72
73EnumValue
74Enum(processor_type) String(z9-109) Value(PROCESSOR_2094_Z9_109)
75
76EnumValue
77Enum(processor_type) String(z9-ec) Value(PROCESSOR_2094_Z9_EC)
78
79EnumValue
80Enum(processor_type) String(arch7) Value(PROCESSOR_2094_Z9_EC)
81
82EnumValue
83Enum(processor_type) String(z10) Value(PROCESSOR_2097_Z10)
84
85EnumValue
86Enum(processor_type) String(arch8) Value(PROCESSOR_2097_Z10)
87
88EnumValue
89Enum(processor_type) String(z196) Value(PROCESSOR_2817_Z196)
90
91EnumValue
92Enum(processor_type) String(arch9) Value(PROCESSOR_2817_Z196)
93
94EnumValue
95Enum(processor_type) String(zEC12) Value(PROCESSOR_2827_ZEC12)
96
97EnumValue
98Enum(processor_type) String(arch10) Value(PROCESSOR_2827_ZEC12)
99
100EnumValue
101Enum(processor_type) String(z13) Value(PROCESSOR_2964_Z13)
102
103EnumValue
104Enum(processor_type) String(arch11) Value(PROCESSOR_2964_Z13)
105
106EnumValue
107Enum(processor_type) String(z14) Value(PROCESSOR_3906_Z14)
108
109EnumValue
110Enum(processor_type) String(arch12) Value(PROCESSOR_3906_Z14)
111
112EnumValue
113Enum(processor_type) String(z15) Value(PROCESSOR_8561_Z15)
114
115EnumValue
116Enum(processor_type) String(arch13) Value(PROCESSOR_8561_Z15)
117
118EnumValue
119Enum(processor_type) String(native) Value(PROCESSOR_NATIVE) DriverOnly
120
121mbackchain
122Target Report Mask(BACKCHAIN) Save
123Maintain backchain pointer.
124
125mdebug
126Target Report Mask(DEBUG_ARG) Save
127Additional debug prints.
128
129mesa
130Target Report RejectNegative Negative(mzarch) InverseMask(ZARCH)
131ESA/390 architecture.
132
133mhard-dfp
134Target Report Mask(HARD_DFP) Save
135Enable decimal floating point hardware support.
136
137mhard-float
138Target Report RejectNegative Negative(msoft-float) InverseMask(SOFT_FLOAT, HARD_FLOAT) Save
139Enable hardware floating point.
140
141mhotpatch=
142Target RejectNegative Report Joined Var(s390_deferred_options) Defer
143Takes two non-negative integer numbers separated by a comma.
144Prepend the function label with the number of two-byte Nop
145instructions indicated by the first.  Append Nop instructions
146covering the number of halfwords indicated by the second after the
147label.  Nop instructions of the largest possible size are used
148(six, four or two bytes), beginning with the largest possible
149size.  Using 0 for both values disables hotpatching.
150
151mlong-double-128
152Target Report RejectNegative Negative(mlong-double-64) Mask(LONG_DOUBLE_128)
153Use 128-bit long double.
154
155mlong-double-64
156Target Report RejectNegative Negative(mlong-double-128) InverseMask(LONG_DOUBLE_128)
157Use 64-bit long double.
158
159mhtm
160Target Report Mask(OPT_HTM) Save
161Use hardware transactional execution instructions.
162
163mvx
164Target Report Mask(OPT_VX) Save
165Use hardware vector facility instructions and enable the vector ABI.
166
167mpacked-stack
168Target Report Mask(PACKED_STACK) Save
169Use packed stack layout.
170
171msmall-exec
172Target Report Mask(SMALL_EXEC) Save
173Use bras for executable < 64k.
174
175msoft-float
176Target Report RejectNegative Negative(mhard-float) Mask(SOFT_FLOAT) Save
177Disable hardware floating point.
178
179mstack-guard=
180Target RejectNegative Negative(mno-stack-guard) Joined UInteger Var(s390_stack_guard) Save
181Set the max. number of bytes which has to be left to stack size before a trap instruction is triggered.
182
183mno-stack-guard
184Target RejectNegative Alias(mstack-guard=,0) Negative(mstack-guard=)
185Switches off the -mstack-guard= option.
186
187mstack-size=
188Target RejectNegative Joined UInteger Var(s390_stack_size) Save
189Emit extra code in the function prologue in order to trap if the stack size exceeds the given limit.
190
191mno-stack-size
192Target RejectNegative Alias(mstack-size=,0) Negative(mstack-size=)
193Switches off the -mstack-size= option.
194
195mtune=
196Target RejectNegative Joined Enum(processor_type) Var(s390_tune) Init(PROCESSOR_max) Save
197Schedule code for given CPU.
198
199mmvcle
200Target Report Mask(MVCLE) Save
201Use the mvcle instruction for block moves.
202
203mzvector
204Target Report Mask(ZVECTOR) Save
205Enable the z vector language extension providing the context-sensitive
206vector macro and enable the Altivec-style builtins in vecintrin.h.
207
208mwarn-dynamicstack
209Target Var(s390_warn_dynamicstack_p) Save
210Warn if a function uses alloca or creates an array with dynamic size.
211
212mwarn-framesize=
213Target RejectNegative Joined UInteger Var(s390_warn_framesize) Save
214Warn if a single function's framesize exceeds the given framesize.
215
216mzarch
217Target Report RejectNegative Negative(mesa) Mask(ZARCH)
218z/Architecture.
219
220mbranch-cost=
221Target Report Joined RejectNegative UInteger Var(s390_branch_cost) Init(1) Save
222Set the branch costs for conditional branch instructions.  Reasonable
223values are small, non-negative integers.  The default branch cost is
2241.
225
226mlra
227Target Report Var(s390_lra_flag) Init(1) Save
228Use LRA instead of reload.
229
230mpic-data-is-text-relative
231Target Report Var(s390_pic_data_is_text_relative) Init(TARGET_DEFAULT_PIC_DATA_IS_TEXT_RELATIVE)
232Assume data segments are relative to text segment.
233
234
235mindirect-branch=
236Target Report RejectNegative Joined Enum(indirect_branch) Var(s390_indirect_branch) Init(indirect_branch_keep)
237Wrap all indirect branches into execute in order to disable branch
238prediction.
239
240mindirect-branch-jump=
241Target Report RejectNegative Joined Enum(indirect_branch) Var(s390_indirect_branch_jump) Init(indirect_branch_keep)
242Wrap indirect table jumps and computed gotos into execute in order to
243disable branch prediction.  Using thunk or thunk-extern with this
244option requires the thunks to be considered signal handlers to order to
245generate correct CFI.  For environments where unwinding (e.g. for
246exceptions) is required please use thunk-inline instead.
247
248mindirect-branch-call=
249Target Report RejectNegative Joined Enum(indirect_branch) Var(s390_indirect_branch_call) Init(indirect_branch_keep)
250Wrap all indirect calls into execute in order to disable branch prediction.
251
252mfunction-return=
253Target Report RejectNegative Joined Enum(indirect_branch) Var(s390_function_return) Init(indirect_branch_keep)
254Wrap all indirect return branches into execute in order to disable branch
255prediction.
256
257mfunction-return-mem=
258Target Report RejectNegative Joined Enum(indirect_branch) Var(s390_function_return_mem) Init(indirect_branch_keep)
259Wrap indirect return branches into execute in order to disable branch
260prediction. This affects only branches where the return address is
261going to be restored from memory.
262
263mfunction-return-reg=
264Target Report RejectNegative Joined Enum(indirect_branch) Var(s390_function_return_reg) Init(indirect_branch_keep)
265Wrap indirect return branches into execute in order to disable branch
266prediction. This affects only branches where the return address
267doesn't need to be restored from memory.
268
269Enum
270Name(indirect_branch) Type(enum indirect_branch)
271Known indirect branch choices (for use with the -mindirect-branch=/-mfunction-return= options):
272
273EnumValue
274Enum(indirect_branch) String(keep) Value(indirect_branch_keep)
275
276EnumValue
277Enum(indirect_branch) String(thunk) Value(indirect_branch_thunk)
278
279EnumValue
280Enum(indirect_branch) String(thunk-inline) Value(indirect_branch_thunk_inline)
281
282EnumValue
283Enum(indirect_branch) String(thunk-extern) Value(indirect_branch_thunk_extern)
284
285mindirect-branch-table
286Target Report Var(s390_indirect_branch_table) Init(TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
287Generate sections .s390_indirect_jump, .s390_indirect_call,
288.s390_return_reg, and .s390_return_mem to contain the indirect branch
289locations which have been patched as part of using one of the
290-mindirect-branch* or -mfunction-return* options.  The sections
291consist of an array of 32 bit elements. Each entry holds the offset
292from the entry to the patched location.
293
294mfentry
295Target Report Var(flag_fentry)
296Emit profiling counter call at function entry before prologue. The compiled
297code will require a 64-bit CPU and glibc 2.29 or newer to run.
298
299mrecord-mcount
300Target Report Var(flag_record_mcount)
301Generate __mcount_loc section with all _mcount and __fentry__ calls.
302
303mnop-mcount
304Target Report Var(flag_nop_mcount)
305Generate mcount/__fentry__ calls as nops. To activate they need to be
306patched in.
307