swr: [rasterizer scripts] add ENABLE_ASSERT_DIALOGS knob for windows
[mesa.git] / src / gallium / drivers / swr / rasterizer / scripts / knob_defs.py
1 # Copyright (C) 2014-2016 Intel Corporation. All Rights Reserved.
2 #
3 # Permission is hereby granted, free of charge, to any person obtaining a
4 # copy of this software and associated documentation files (the "Software"),
5 # to deal in the Software without restriction, including without limitation
6 # the rights to use, copy, modify, merge, publish, distribute, sublicense,
7 # and/or sell copies of the Software, and to permit persons to whom the
8 # Software is furnished to do so, subject to the following conditions:
9 #
10 # The above copyright notice and this permission notice (including the next
11 # paragraph) shall be included in all copies or substantial portions of the
12 # Software.
13 #
14 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
17 # THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18 # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
19 # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
20 # IN THE SOFTWARE.
21
22 # Python source
23 KNOBS = [
24
25 ['ENABLE_ASSERT_DIALOGS', {
26 'type' : 'bool',
27 'default' : 'true',
28 'desc' : ['Use dialogs when asserts fire.',
29 'Asserts are only enabled in debug builds'],
30 'category' : 'debug',
31 }],
32
33 ['SINGLE_THREADED', {
34 'type' : 'bool',
35 'default' : 'false',
36 'desc' : ['If enabled will perform all rendering on the API thread.',
37 'This is useful mainly for debugging purposes.'],
38 'category' : 'debug',
39 }],
40
41 ['DUMP_SHADER_IR', {
42 'type' : 'bool',
43 'default' : 'false',
44 'desc' : ['Dumps shader LLVM IR at various stages of jit compilation.'],
45 'category' : 'debug',
46 }],
47
48 ['USE_GENERIC_STORETILE', {
49 'type' : 'bool',
50 'default' : 'false',
51 'desc' : ['Always use generic function for performing StoreTile.',
52 'Will be slightly slower than using optimized (jitted) path'],
53 'category' : 'debug',
54 }],
55
56 ['FAST_CLEAR', {
57 'type' : 'bool',
58 'default' : 'true',
59 'desc' : ['Replace 3D primitive execute with a SWRClearRT operation and',
60 'defer clear execution to first backend op on hottile, or hottile store'],
61 'category' : 'perf',
62 }],
63
64 ['MAX_NUMA_NODES', {
65 'type' : 'uint32_t',
66 'default' : '0',
67 'desc' : ['Maximum # of NUMA-nodes per system used for worker threads',
68 ' 0 == ALL NUMA-nodes in the system',
69 ' N == Use at most N NUMA-nodes for rendering'],
70 'category' : 'perf',
71 }],
72
73 ['MAX_CORES_PER_NUMA_NODE', {
74 'type' : 'uint32_t',
75 'default' : '0',
76 'desc' : ['Maximum # of cores per NUMA-node used for worker threads.',
77 ' 0 == ALL non-API thread cores per NUMA-node',
78 ' N == Use at most N cores per NUMA-node'],
79 'category' : 'perf',
80 }],
81
82 ['MAX_THREADS_PER_CORE', {
83 'type' : 'uint32_t',
84 'default' : '1',
85 'desc' : ['Maximum # of (hyper)threads per physical core used for worker threads.',
86 ' 0 == ALL hyper-threads per core',
87 ' N == Use at most N hyper-threads per physical core'],
88 'category' : 'perf',
89 }],
90
91 ['MAX_WORKER_THREADS', {
92 'type' : 'uint32_t',
93 'default' : '0',
94 'desc' : ['Maximum worker threads to spawn.',
95 '',
96 'IMPORTANT: If this is non-zero, no worker threads will be bound to',
97 'specific HW threads. They will all be "floating" SW threads.',
98 'In this case, the above 3 KNOBS will be ignored.'],
99 'category' : 'perf',
100 }],
101
102 ['BUCKETS_START_FRAME', {
103 'type' : 'uint32_t',
104 'default' : '1200',
105 'desc' : ['Frame from when to start saving buckets data.',
106 '',
107 'NOTE: KNOB_ENABLE_RDTSC must be enabled in core/knobs.h',
108 'for this to have an effect.'],
109 'category' : 'perf',
110 }],
111
112 ['BUCKETS_END_FRAME', {
113 'type' : 'uint32_t',
114 'default' : '1400',
115 'desc' : ['Frame at which to stop saving buckets data.',
116 '',
117 'NOTE: KNOB_ENABLE_RDTSC must be enabled in core/knobs.h',
118 'for this to have an effect.'],
119 'category' : 'perf',
120 }],
121
122 ['WORKER_SPIN_LOOP_COUNT', {
123 'type' : 'uint32_t',
124 'default' : '5000',
125 'desc' : ['Number of spin-loop iterations worker threads will perform',
126 'before going to sleep when waiting for work'],
127 'category' : 'perf',
128 }],
129
130 ['MAX_DRAWS_IN_FLIGHT', {
131 'type' : 'uint32_t',
132 'default' : '128',
133 'desc' : ['Maximum number of draws outstanding before API thread blocks.',
134 'This value MUST be evenly divisible into 2^32'],
135 'category' : 'perf',
136 }],
137
138 ['MAX_PRIMS_PER_DRAW', {
139 'type' : 'uint32_t',
140 'default' : '2040',
141 'desc' : ['Maximum primitives in a single Draw().',
142 'Larger primitives are split into smaller Draw calls.',
143 'Should be a multiple of (3 * vectorWidth).'],
144 'category' : 'perf',
145 }],
146
147 ['MAX_TESS_PRIMS_PER_DRAW', {
148 'type' : 'uint32_t',
149 'default' : '16',
150 'desc' : ['Maximum primitives in a single Draw() with tessellation enabled.',
151 'Larger primitives are split into smaller Draw calls.',
152 'Should be a multiple of (vectorWidth).'],
153 'category' : 'perf',
154 }],
155
156
157 ['TOSS_DRAW', {
158 'type' : 'bool',
159 'default' : 'false',
160 'desc' : ['Disable per-draw/dispatch execution'],
161 'category' : 'perf',
162 }],
163
164 ['TOSS_QUEUE_FE', {
165 'type' : 'bool',
166 'default' : 'false',
167 'desc' : ['Stop per-draw execution at worker FE',
168 '',
169 'NOTE: Requires KNOB_ENABLE_TOSS_POINTS to be enabled in core/knobs.h'],
170 'category' : 'perf',
171 'advanced' : 'true',
172 }],
173
174 ['TOSS_FETCH', {
175 'type' : 'bool',
176 'default' : 'false',
177 'desc' : ['Stop per-draw execution at vertex fetch',
178 '',
179 'NOTE: Requires KNOB_ENABLE_TOSS_POINTS to be enabled in core/knobs.h'],
180 'category' : 'perf',
181 'advanced' : 'true',
182 }],
183
184 ['TOSS_IA', {
185 'type' : 'bool',
186 'default' : 'false',
187 'desc' : ['Stop per-draw execution at input assembler',
188 '',
189 'NOTE: Requires KNOB_ENABLE_TOSS_POINTS to be enabled in core/knobs.h'],
190 'category' : 'perf',
191 'advanced' : 'true',
192 }],
193
194 ['TOSS_VS', {
195 'type' : 'bool',
196 'default' : 'false',
197 'desc' : ['Stop per-draw execution at vertex shader',
198 '',
199 'NOTE: Requires KNOB_ENABLE_TOSS_POINTS to be enabled in core/knobs.h'],
200 'category' : 'perf',
201 'advanced' : 'true',
202 }],
203
204 ['TOSS_SETUP_TRIS', {
205 'type' : 'bool',
206 'default' : 'false',
207 'desc' : ['Stop per-draw execution at primitive setup',
208 '',
209 'NOTE: Requires KNOB_ENABLE_TOSS_POINTS to be enabled in core/knobs.h'],
210 'category' : 'perf',
211 'advanced' : 'true',
212 }],
213
214 ['TOSS_BIN_TRIS', {
215 'type' : 'bool',
216 'default' : 'false',
217 'desc' : ['Stop per-draw execution at primitive binning',
218 '',
219 'NOTE: Requires KNOB_ENABLE_TOSS_POINTS to be enabled in core/knobs.h'],
220 'category' : 'perf',
221 'advanced' : 'true',
222 }],
223
224 ['TOSS_RS', {
225 'type' : 'bool',
226 'default' : 'false',
227 'desc' : ['Stop per-draw execution at rasterizer',
228 '',
229 'NOTE: Requires KNOB_ENABLE_TOSS_POINTS to be enabled in core/knobs.h'],
230 'category' : 'perf',
231 'advanced' : 'true',
232 }],
233
234 ]