2004-08-18 David Daney <ddaney@avtrex.com>
[official-gcc.git] / gcc / params.def
blobaed7655c9a45df4506dda95855130306f272d2ba
1 /* params.def - Run-time parameters.
2 Copyright (C) 2001, 2002, 2004 Free Software Foundation, Inc.
3 Written by Mark Mitchell <mark@codesourcery.com>.
5 This file is part of GCC.
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 2, or (at your option) any later
10 version.
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.
17 You should have received a copy of the GNU General Public License
18 along with GCC; see the file COPYING. If not, write to the Free
19 Software Foundation, 59 Temple Place - Suite 330, Boston, MA
20 02111-1307, USA.
24 /* This file contains definitions for language-independent
25 parameters. The DEFPARAM macro takes 4 arguments:
27 - The enumeral corresponding to this parameter.
29 - The name that can be used to set this parameter using the
30 command-line option `--param <name>=<value>'.
32 - A help string explaining how the parameter is used.
34 - A default value for the parameter.
36 Be sure to add an entry to invoke.texi summarizing the parameter. */
38 /* The single function inlining limit. This is the maximum size
39 of a function counted in internal gcc instructions (not in
40 real machine instructions) that is eligible for inlining
41 by the tree inliner.
42 The default value is 500.
43 Only functions marked inline (or methods defined in the class
44 definition for C++) are affected by this, unless you set the
45 -finline-functions (included in -O3) compiler option.
46 There are more restrictions to inlining: If inlined functions
47 call other functions, the already inlined instructions are
48 counted and once the recursive inline limit (see
49 "max-inline-insns" parameter) is exceeded, the acceptable size
50 gets decreased. */
51 DEFPARAM (PARAM_MAX_INLINE_INSNS_SINGLE,
52 "max-inline-insns-single",
53 "The maximum number of instructions in a single function eligible for inlining",
54 500)
56 /* The single function inlining limit for functions that are
57 inlined by virtue of -finline-functions (-O3).
58 This limit should be chosen to be below or equal to the limit
59 that is applied to functions marked inlined (or defined in the
60 class declaration in C++) given by the "max-inline-insns-single"
61 parameter.
62 The default value is 150. */
63 DEFPARAM (PARAM_MAX_INLINE_INSNS_AUTO,
64 "max-inline-insns-auto",
65 "The maximum number of instructions when automatically inlining",
66 120)
68 DEFPARAM (PARAM_MAX_INLINE_INSNS_RECURSIVE,
69 "max-inline-insns-recursive",
70 "The maximum number of instructions inline function can grow to via recursive inlining",
71 500)
73 DEFPARAM (PARAM_MAX_INLINE_INSNS_RECURSIVE_AUTO,
74 "max-inline-insns-recursive-auto",
75 "The maximum number of instructions non-inline function can grow to via recursive inlining",
76 500)
78 DEFPARAM (PARAM_MAX_INLINE_RECURSIVE_DEPTH,
79 "max-inline-recursive-depth",
80 "The maximum depth of recursive inlining for inline functions",
83 DEFPARAM (PARAM_MAX_INLINE_RECURSIVE_DEPTH_AUTO,
84 "max-inline-recursive-depth-auto",
85 "The maximum depth of recursive inlining for non-inline functions",
88 /* For languages that (still) use the RTL inliner, we can specify
89 limits for the RTL inliner separately.
90 The parameter here defines the maximum number of RTL instructions
91 a function may have to be eligible for inlining in the RTL inliner.
92 The default value is 600. */
93 DEFPARAM (PARAM_MAX_INLINE_INSNS_RTL,
94 "max-inline-insns-rtl",
95 "The maximum number of instructions for the RTL inliner",
96 600)
98 /* The maximum number of instructions to consider when looking for an
99 instruction to fill a delay slot. If more than this arbitrary
100 number of instructions is searched, the time savings from filling
101 the delay slot will be minimal so stop searching. Increasing
102 values mean more aggressive optimization, making the compile time
103 increase with probably small improvement in executable run time. */
104 DEFPARAM (PARAM_MAX_DELAY_SLOT_INSN_SEARCH,
105 "max-delay-slot-insn-search",
106 "The maximum number of instructions to consider to fill a delay slot",
107 100)
109 /* When trying to fill delay slots, the maximum number of instructions
110 to consider when searching for a block with valid live register
111 information. Increasing this arbitrarily chosen value means more
112 aggressive optimization, increasing the compile time. This
113 parameter should be removed when the delay slot code is rewritten
114 to maintain the control-flow graph. */
115 DEFPARAM(PARAM_MAX_DELAY_SLOT_LIVE_SEARCH,
116 "max-delay-slot-live-search",
117 "The maximum number of instructions to consider to find accurate live register information",
118 333)
120 /* This parameter limits the number of branch elements that the
121 scheduler will track anti-dependencies through without resetting
122 the tracking mechanism. Large functions with few calls or barriers
123 can generate lists containing many 1000's of dependencies. Generally
124 the compiler either uses all available memory, or runs for far too long. */
125 DEFPARAM(PARAM_MAX_PENDING_LIST_LENGTH,
126 "max-pending-list-length",
127 "The maximum length of scheduling's pending operations list",
130 DEFPARAM(PARAM_LARGE_FUNCTION_INSNS,
131 "large-function-insns",
132 "The size of function body to be considered large",
133 3000)
134 DEFPARAM(PARAM_LARGE_FUNCTION_GROWTH,
135 "large-function-growth",
136 "Maximal growth due to inlining of large function (in percent)",
137 100)
138 DEFPARAM(PARAM_INLINE_UNIT_GROWTH,
139 "inline-unit-growth",
140 "how much can given compilation unit grow because of the inlining (in percent)",
143 /* The GCSE optimization will be disabled if it would require
144 significantly more memory than this value. */
145 DEFPARAM(PARAM_MAX_GCSE_MEMORY,
146 "max-gcse-memory",
147 "The maximum amount of memory to be allocated by GCSE",
148 50 * 1024 * 1024)
149 /* The number of repetitions of copy/const prop and PRE to run. */
150 DEFPARAM(PARAM_MAX_GCSE_PASSES,
151 "max-gcse-passes",
152 "The maximum number of passes to make when doing GCSE",
154 /* This is the threshold ratio when to perform partial redundancy
155 elimination after reload. We perform partial redundancy elimination
156 when the following holds:
157 (Redundant load execution count)
158 ------------------------------- >= GCSE_AFTER_RELOAD_PARTIAL_FRACTION
159 (Added loads execution count) */
160 DEFPARAM(PARAM_GCSE_AFTER_RELOAD_PARTIAL_FRACTION,
161 "gcse-after-reload-partial-fraction",
162 "The threshold ratio for performing partial redundancy elimination \
163 after reload.",
165 /* This is the threshold ratio of the critical edges execution count compared to
166 the redundant loads execution count that permits performing the load
167 redundancy elimination in gcse after reload. */
168 DEFPARAM(PARAM_GCSE_AFTER_RELOAD_CRITICAL_FRACTION,
169 "gcse-after-reload-critical-fraction",
170 "The threshold ratio of critical edges execution count that permit \
171 performing redundancy elimination after reload.",
173 /* This parameter limits the number of insns in a loop that will be unrolled,
174 and by how much the loop is unrolled.
176 This limit should be at most half of the peeling limits: loop unroller
177 decides to not unroll loops that iterate fewer than 2*number of allowed
178 unrollings and thus we would have loops that are neither peeled or unrolled
179 otherwise. */
180 DEFPARAM(PARAM_MAX_UNROLLED_INSNS,
181 "max-unrolled-insns",
182 "The maximum number of instructions to consider to unroll in a loop",
183 200)
184 /* This parameter limits how many times the loop is unrolled depending
185 on number of insns really executed in each iteration. */
186 DEFPARAM(PARAM_MAX_AVERAGE_UNROLLED_INSNS,
187 "max-average-unrolled-insns",
188 "The maximum number of instructions to consider to unroll in a loop on average",
190 /* The maximum number of unrollings of a single loop. */
191 DEFPARAM(PARAM_MAX_UNROLL_TIMES,
192 "max-unroll-times",
193 "The maximum number of unrollings of a single loop",
195 /* The maximum number of insns of a peeled loop. */
196 DEFPARAM(PARAM_MAX_PEELED_INSNS,
197 "max-peeled-insns",
198 "The maximum number of insns of a peeled loop",
199 400)
200 /* The maximum number of peelings of a single loop. */
201 DEFPARAM(PARAM_MAX_PEEL_TIMES,
202 "max-peel-times",
203 "The maximum number of peelings of a single loop",
205 /* The maximum number of insns of a peeled loop. */
206 DEFPARAM(PARAM_MAX_COMPLETELY_PEELED_INSNS,
207 "max-completely-peeled-insns",
208 "The maximum number of insns of a completely peeled loop",
209 400)
210 /* The maximum number of peelings of a single loop that is peeled completely. */
211 DEFPARAM(PARAM_MAX_COMPLETELY_PEEL_TIMES,
212 "max-completely-peel-times",
213 "The maximum number of peelings of a single loop that is peeled completely",
215 /* The maximum number of insns of a peeled loop that rolls only once. */
216 DEFPARAM(PARAM_MAX_ONCE_PEELED_INSNS,
217 "max-once-peeled-insns",
218 "The maximum number of insns of a peeled loop that rolls only once",
219 400)
221 /* The maximum number of insns of an unswitched loop. */
222 DEFPARAM(PARAM_MAX_UNSWITCH_INSNS,
223 "max-unswitch-insns",
224 "The maximum number of insns of an unswitched loop",
226 /* The maximum level of recursion in unswitch_single_loop. */
227 DEFPARAM(PARAM_MAX_UNSWITCH_LEVEL,
228 "max-unswitch-level",
229 "The maximum number of unswitchings in a single loop",
232 /* The maximum number of iterations of a loop the brute force algorithm
233 for analysis of # of iterations of the loop tries to evaluate. */
234 DEFPARAM(PARAM_MAX_ITERATIONS_TO_TRACK,
235 "max-iterations-to-track",
236 "Bound on the number of iterations the brute force # of iterations \
237 analysis algorithm evaluates",
238 1000)
240 DEFPARAM(PARAM_MAX_SMS_LOOP_NUMBER,
241 "max-sms-loop-number",
242 "Maximum number of loops to perform swing modulo scheduling on \
243 (mainly for debugging)",
246 /* This parameter is used to tune SMS MAX II calculations. */
247 DEFPARAM(PARAM_SMS_MAX_II_FACTOR,
248 "sms-max-ii-factor",
249 "A factor for tuning the upper bound that swing modulo scheduler uses \
250 for scheduling a loop",
251 100)
252 DEFPARAM(PARAM_SMS_DFA_HISTORY,
253 "sms-dfa-history",
254 "The number of cycles the swing modulo scheduler considers when \
255 checking conflicts using DFA",
257 DEFPARAM(PARAM_SMS_LOOP_AVERAGE_COUNT_THRESHOLD,
258 "sms-loop-average-count-threshold",
259 "A threshold on the average loop count considered by the swing modulo \
260 scheduler",
263 DEFPARAM(HOT_BB_COUNT_FRACTION,
264 "hot-bb-count-fraction",
265 "Select fraction of the maximal count of repetitions of basic block in \
266 program given basic block needs to have to be considered hot",
267 10000)
268 DEFPARAM(HOT_BB_FREQUENCY_FRACTION,
269 "hot-bb-frequency-fraction",
270 "Select fraction of the maximal frequency of executions of basic \
271 block in function given basic block needs to have to be considered hot",
272 1000)
273 DEFPARAM(TRACER_DYNAMIC_COVERAGE_FEEDBACK,
274 "tracer-dynamic-coverage-feedback",
275 "The percentage of function, weighted by execution frequency, that \
276 must be covered by trace formation. Used when profile feedback is available",
278 DEFPARAM(TRACER_DYNAMIC_COVERAGE,
279 "tracer-dynamic-coverage",
280 "The percentage of function, weighted by execution frequency, that \
281 must be covered by trace formation. Used when profile feedback is not available",
283 DEFPARAM(TRACER_MAX_CODE_GROWTH,
284 "tracer-max-code-growth",
285 "Maximal code growth caused by tail duplication (in percent)",
286 100)
287 DEFPARAM(TRACER_MIN_BRANCH_RATIO,
288 "tracer-min-branch-ratio",
289 "Stop reverse growth if the reverse probability of best edge is less \
290 than this threshold (in percent)",
292 DEFPARAM(TRACER_MIN_BRANCH_PROBABILITY_FEEDBACK,
293 "tracer-min-branch-probability-feedback",
294 "Stop forward growth if the probability of best edge is less than \
295 this threshold (in percent). Used when profile feedback is available",
297 DEFPARAM(TRACER_MIN_BRANCH_PROBABILITY,
298 "tracer-min-branch-probability",
299 "Stop forward growth if the probability of best edge is less than \
300 this threshold (in percent). Used when profile feedback is not available",
303 /* The maximum number of incoming edges to consider for crossjumping. */
304 DEFPARAM(PARAM_MAX_CROSSJUMP_EDGES,
305 "max-crossjump-edges",
306 "The maximum number of incoming edges to consider for crossjumping",
307 100)
309 /* The minimum number of matching instructions to consider for crossjumping. */
310 DEFPARAM(PARAM_MIN_CROSSJUMP_INSNS,
311 "min-crossjump-insns",
312 "The minimum number of matching instructions to consider for crossjumping",
315 /* The maximum length of path considered in cse. */
316 DEFPARAM(PARAM_MAX_CSE_PATH_LENGTH,
317 "max-cse-path-length",
318 "The maximum length of path considered in cse",
321 /* The cost of expression in loop invariant motion that is considered
322 expensive. */
323 DEFPARAM(PARAM_LIM_EXPENSIVE,
324 "lim-expensive",
325 "The minimum cost of an expensive expression in the loop invariant motion",
328 /* The product of the next two is used to decide whether or not to
329 use .GLOBAL_VAR. See tree-dfa.c. */
330 DEFPARAM(PARAM_GLOBAL_VAR_THRESHOLD,
331 "global-var-threshold",
332 "Given N calls and V call-clobbered vars in a function. Use .GLOBAL_VAR if NxV is larger than this limit",
333 500000)
335 DEFPARAM(PARAM_MAX_CSELIB_MEMORY_LOCATIONS,
336 "max-cselib-memory-locations",
337 "The maximum memory locations recorded by cselib",
338 500)
340 #ifdef ENABLE_GC_ALWAYS_COLLECT
341 # define GGC_MIN_EXPAND_DEFAULT 0
342 # define GGC_MIN_HEAPSIZE_DEFAULT 0
343 #else
344 # define GGC_MIN_EXPAND_DEFAULT 30
345 # define GGC_MIN_HEAPSIZE_DEFAULT 4096
346 #endif
348 DEFPARAM(GGC_MIN_EXPAND,
349 "ggc-min-expand",
350 "Minimum heap expansion to trigger garbage collection, as \
351 a percentage of the total size of the heap",
352 GGC_MIN_EXPAND_DEFAULT)
354 DEFPARAM(GGC_MIN_HEAPSIZE,
355 "ggc-min-heapsize",
356 "Minimum heap size before we start collecting garbage, in kilobytes",
357 GGC_MIN_HEAPSIZE_DEFAULT)
359 #undef GGC_MIN_EXPAND_DEFAULT
360 #undef GGC_MIN_HEAPSIZE_DEFAULT
362 DEFPARAM(PARAM_MAX_RELOAD_SEARCH_INSNS,
363 "max-reload-search-insns",
364 "The maximum number of instructions to search backward when looking for equivalent reload",
365 100)
367 DEFPARAM(PARAM_MAX_ALIASED_VOPS,
368 "max-aliased-vops",
369 "The maximum number of virtual operands allowed to represent aliases before triggering alias grouping.",
370 500)
372 DEFPARAM(PARAM_MAX_SCHED_REGION_BLOCKS,
373 "max-sched-region-blocks",
374 "The maximum number of blocks in a region to be considered for interblock scheduling",
377 DEFPARAM(PARAM_MAX_SCHED_REGION_INSNS,
378 "max-sched-region-insns",
379 "The maximum number of insns in a region to be considered for interblock scheduling",
380 100)
383 Local variables:
384 mode:c
385 End: */