]>
Commit | Line | Data |
---|---|---|
b31b4d6a SP |
1 | @node Tunables |
2 | @c @node Tunables, , Internal Probes, Top | |
3 | @c %MENU% Tunable switches to alter libc internal behavior | |
4 | @chapter Tunables | |
5 | @cindex tunables | |
6 | ||
7 | @dfn{Tunables} are a feature in @theglibc{} that allows application authors and | |
8 | distribution maintainers to alter the runtime library behavior to match | |
9 | their workload. These are implemented as a set of switches that may be | |
10 | modified in different ways. The current default method to do this is via | |
11 | the @env{GLIBC_TUNABLES} environment variable by setting it to a string | |
12 | of colon-separated @var{name}=@var{value} pairs. For example, the following | |
13 | example enables malloc checking and sets the malloc trim threshold to 128 | |
14 | bytes: | |
15 | ||
16 | @example | |
17 | GLIBC_TUNABLES=glibc.malloc.trim_threshold=128:glibc.malloc.check=3 | |
18 | export GLIBC_TUNABLES | |
19 | @end example | |
20 | ||
21 | Tunables are not part of the @glibcadj{} stable ABI, and they are | |
22 | subject to change or removal across releases. Additionally, the method to | |
23 | modify tunable values may change between releases and across distributions. | |
24 | It is possible to implement multiple `frontends' for the tunables allowing | |
25 | distributions to choose their preferred method at build time. | |
26 | ||
27 | Finally, the set of tunables available may vary between distributions as | |
28 | the tunables feature allows distributions to add their own tunables under | |
29 | their own namespace. | |
30 | ||
31 | @menu | |
32 | * Tunable names:: The structure of a tunable name | |
33 | * Memory Allocation Tunables:: Tunables in the memory allocation subsystem | |
0c7b002f | 34 | * Dynamic Linking Tunables:: Tunables in the dynamic linking subsystem |
07ed18d2 | 35 | * Elision Tunables:: Tunables in elision subsystem |
6310e6be | 36 | * POSIX Thread Tunables:: Tunables in the POSIX thread subsystem |
ea9b0ecb SP |
37 | * Hardware Capability Tunables:: Tunables that modify the hardware |
38 | capabilities seen by @theglibc{} | |
b31b4d6a SP |
39 | @end menu |
40 | ||
41 | @node Tunable names | |
42 | @section Tunable names | |
43 | @cindex Tunable names | |
44 | @cindex Tunable namespaces | |
45 | ||
46 | A tunable name is split into three components, a top namespace, a tunable | |
47 | namespace and the tunable name. The top namespace for tunables implemented in | |
48 | @theglibc{} is @code{glibc}. Distributions that choose to add custom tunables | |
49 | in their maintained versions of @theglibc{} may choose to do so under their own | |
50 | top namespace. | |
51 | ||
52 | The tunable namespace is a logical grouping of tunables in a single | |
53 | module. This currently holds no special significance, although that may | |
54 | change in the future. | |
55 | ||
56 | The tunable name is the actual name of the tunable. It is possible that | |
57 | different tunable namespaces may have tunables within them that have the | |
58 | same name, likewise for top namespaces. Hence, we only support | |
59 | identification of tunables by their full name, i.e. with the top | |
60 | namespace, tunable namespace and tunable name, separated by periods. | |
61 | ||
62 | @node Memory Allocation Tunables | |
63 | @section Memory Allocation Tunables | |
64 | @cindex memory allocation tunables | |
65 | @cindex malloc tunables | |
66 | @cindex tunables, malloc | |
67 | ||
68 | @deftp {Tunable namespace} glibc.malloc | |
69 | Memory allocation behavior can be modified by setting any of the | |
70 | following tunables in the @code{malloc} namespace: | |
71 | @end deftp | |
72 | ||
73 | @deftp Tunable glibc.malloc.check | |
74 | This tunable supersedes the @env{MALLOC_CHECK_} environment variable and is | |
75 | identical in features. | |
76 | ||
ec2c1fce FW |
77 | Setting this tunable to a non-zero value enables a special (less |
78 | efficient) memory allocator for the malloc family of functions that is | |
79 | designed to be tolerant against simple errors such as double calls of | |
80 | free with the same argument, or overruns of a single byte (off-by-one | |
81 | bugs). Not all such errors can be protected against, however, and memory | |
82 | leaks can result. Any detected heap corruption results in immediate | |
83 | termination of the process. | |
b31b4d6a SP |
84 | |
85 | Like @env{MALLOC_CHECK_}, @code{glibc.malloc.check} has a problem in that it | |
86 | diverges from normal program behavior by writing to @code{stderr}, which could | |
87 | by exploited in SUID and SGID binaries. Therefore, @code{glibc.malloc.check} | |
88 | is disabled by default for SUID and SGID binaries. This can be enabled again | |
89 | by the system administrator by adding a file @file{/etc/suid-debug}; the | |
90 | content of the file could be anything or even empty. | |
91 | @end deftp | |
92 | ||
93 | @deftp Tunable glibc.malloc.top_pad | |
94 | This tunable supersedes the @env{MALLOC_TOP_PAD_} environment variable and is | |
95 | identical in features. | |
96 | ||
97 | This tunable determines the amount of extra memory in bytes to obtain from the | |
98 | system when any of the arenas need to be extended. It also specifies the | |
99 | number of bytes to retain when shrinking any of the arenas. This provides the | |
100 | necessary hysteresis in heap size such that excessive amounts of system calls | |
101 | can be avoided. | |
102 | ||
103 | The default value of this tunable is @samp{0}. | |
104 | @end deftp | |
105 | ||
106 | @deftp Tunable glibc.malloc.perturb | |
107 | This tunable supersedes the @env{MALLOC_PERTURB_} environment variable and is | |
108 | identical in features. | |
109 | ||
110 | If set to a non-zero value, memory blocks are initialized with values depending | |
111 | on some low order bits of this tunable when they are allocated (except when | |
112 | allocated by calloc) and freed. This can be used to debug the use of | |
113 | uninitialized or freed heap memory. Note that this option does not guarantee | |
114 | that the freed block will have any specific values. It only guarantees that the | |
115 | content the block had before it was freed will be overwritten. | |
116 | ||
117 | The default value of this tunable is @samp{0}. | |
118 | @end deftp | |
119 | ||
120 | @deftp Tunable glibc.malloc.mmap_threshold | |
121 | This tunable supersedes the @env{MALLOC_MMAP_THRESHOLD_} environment variable | |
122 | and is identical in features. | |
123 | ||
124 | When this tunable is set, all chunks larger than this value in bytes are | |
125 | allocated outside the normal heap, using the @code{mmap} system call. This way | |
126 | it is guaranteed that the memory for these chunks can be returned to the system | |
127 | on @code{free}. Note that requests smaller than this threshold might still be | |
128 | allocated via @code{mmap}. | |
129 | ||
130 | If this tunable is not set, the default value is set to @samp{131072} bytes and | |
131 | the threshold is adjusted dynamically to suit the allocation patterns of the | |
132 | program. If the tunable is set, the dynamic adjustment is disabled and the | |
133 | value is set as static. | |
134 | @end deftp | |
135 | ||
136 | @deftp Tunable glibc.malloc.trim_threshold | |
137 | This tunable supersedes the @env{MALLOC_TRIM_THRESHOLD_} environment variable | |
138 | and is identical in features. | |
139 | ||
140 | The value of this tunable is the minimum size (in bytes) of the top-most, | |
141 | releasable chunk in an arena that will trigger a system call in order to return | |
142 | memory to the system from that arena. | |
143 | ||
144 | If this tunable is not set, the default value is set as 128 KB and the | |
145 | threshold is adjusted dynamically to suit the allocation patterns of the | |
146 | program. If the tunable is set, the dynamic adjustment is disabled and the | |
147 | value is set as static. | |
148 | @end deftp | |
149 | ||
150 | @deftp Tunable glibc.malloc.mmap_max | |
151 | This tunable supersedes the @env{MALLOC_MMAP_MAX_} environment variable and is | |
152 | identical in features. | |
153 | ||
154 | The value of this tunable is maximum number of chunks to allocate with | |
155 | @code{mmap}. Setting this to zero disables all use of @code{mmap}. | |
156 | ||
157 | The default value of this tunable is @samp{65536}. | |
158 | @end deftp | |
159 | ||
160 | @deftp Tunable glibc.malloc.arena_test | |
161 | This tunable supersedes the @env{MALLOC_ARENA_TEST} environment variable and is | |
162 | identical in features. | |
163 | ||
164 | The @code{glibc.malloc.arena_test} tunable specifies the number of arenas that | |
165 | can be created before the test on the limit to the number of arenas is | |
166 | conducted. The value is ignored if @code{glibc.malloc.arena_max} is set. | |
167 | ||
168 | The default value of this tunable is 2 for 32-bit systems and 8 for 64-bit | |
169 | systems. | |
170 | @end deftp | |
171 | ||
172 | @deftp Tunable glibc.malloc.arena_max | |
173 | This tunable supersedes the @env{MALLOC_ARENA_MAX} environment variable and is | |
174 | identical in features. | |
175 | ||
176 | This tunable sets the number of arenas to use in a process regardless of the | |
177 | number of cores in the system. | |
178 | ||
179 | The default value of this tunable is @code{0}, meaning that the limit on the | |
180 | number of arenas is determined by the number of CPU cores online. For 32-bit | |
181 | systems the limit is twice the number of cores online and on 64-bit systems, it | |
182 | is 8 times the number of cores online. | |
183 | @end deftp | |
ea9b0ecb | 184 | |
d5c3fafc DD |
185 | @deftp Tunable glibc.malloc.tcache_max |
186 | The maximum size of a request (in bytes) which may be met via the | |
187 | per-thread cache. The default (and maximum) value is 1032 bytes on | |
188 | 64-bit systems and 516 bytes on 32-bit systems. | |
189 | @end deftp | |
190 | ||
191 | @deftp Tunable glibc.malloc.tcache_count | |
192 | The maximum number of chunks of each size to cache. The default is 7. | |
1f50f2ad | 193 | The upper limit is 65535. If set to zero, the per-thread cache is effectively |
5ad533e8 | 194 | disabled. |
d5c3fafc DD |
195 | |
196 | The approximate maximum overhead of the per-thread cache is thus equal | |
197 | to the number of bins times the chunk count in each bin times the size | |
198 | of each chunk. With defaults, the approximate maximum overhead of the | |
199 | per-thread cache is approximately 236 KB on 64-bit systems and 118 KB | |
200 | on 32-bit systems. | |
201 | @end deftp | |
202 | ||
203 | @deftp Tunable glibc.malloc.tcache_unsorted_limit | |
204 | When the user requests memory and the request cannot be met via the | |
205 | per-thread cache, the arenas are used to meet the request. At this | |
206 | time, additional chunks will be moved from existing arena lists to | |
207 | pre-fill the corresponding cache. While copies from the fastbins, | |
208 | smallbins, and regular bins are bounded and predictable due to the bin | |
209 | sizes, copies from the unsorted bin are not bounded, and incur | |
210 | additional time penalties as they need to be sorted as they're | |
211 | scanned. To make scanning the unsorted list more predictable and | |
212 | bounded, the user may set this tunable to limit the number of chunks | |
213 | that are scanned from the unsorted list while searching for chunks to | |
214 | pre-fill the per-thread cache with. The default, or when set to zero, | |
215 | is no limit. | |
be8aa923 | 216 | @end deftp |
d5c3fafc | 217 | |
c48d92b4 DD |
218 | @deftp Tunable glibc.malloc.mxfast |
219 | One of the optimizations malloc uses is to maintain a series of ``fast | |
220 | bins'' that hold chunks up to a specific size. The default and | |
221 | maximum size which may be held this way is 80 bytes on 32-bit systems | |
222 | or 160 bytes on 64-bit systems. Applications which value size over | |
223 | speed may choose to reduce the size of requests which are serviced | |
224 | from fast bins with this tunable. Note that the value specified | |
225 | includes malloc's internal overhead, which is normally the size of one | |
226 | pointer, so add 4 on 32-bit systems or 8 on 64-bit systems to the size | |
227 | passed to @code{malloc} for the largest bin size to enable. | |
228 | @end deftp | |
229 | ||
0c7b002f SN |
230 | @node Dynamic Linking Tunables |
231 | @section Dynamic Linking Tunables | |
232 | @cindex dynamic linking tunables | |
233 | @cindex rtld tunables | |
234 | ||
235 | @deftp {Tunable namespace} glibc.rtld | |
236 | Dynamic linker behavior can be modified by setting the | |
237 | following tunables in the @code{rtld} namespace: | |
238 | @end deftp | |
239 | ||
240 | @deftp Tunable glibc.rtld.nns | |
241 | Sets the number of supported dynamic link namespaces (see @code{dlmopen}). | |
242 | Currently this limit can be set between 1 and 16 inclusive, the default is 4. | |
243 | Each link namespace consumes some memory in all thread, and thus raising the | |
244 | limit will increase the amount of memory each thread uses. Raising the limit | |
17796419 SN |
245 | is useful when your application uses more than 4 dynamic link namespaces as |
246 | created by @code{dlmopen} with an lmid argument of @code{LM_ID_NEWLM}. | |
247 | Dynamic linker audit modules are loaded in their own dynamic link namespaces, | |
248 | but they are not accounted for in @code{glibc.rtld.nns}. They implicitly | |
249 | increase the per-thread memory usage as necessary, so this tunable does | |
250 | not need to be changed to allow many audit modules e.g. via @env{LD_AUDIT}. | |
0c7b002f SN |
251 | @end deftp |
252 | ||
ffb17e7b SN |
253 | @deftp Tunable glibc.rtld.optional_static_tls |
254 | Sets the amount of surplus static TLS in bytes to allocate at program | |
255 | startup. Every thread created allocates this amount of specified surplus | |
256 | static TLS. This is a minimum value and additional space may be allocated | |
257 | for internal purposes including alignment. Optional static TLS is used for | |
258 | optimizing dynamic TLS access for platforms that support such optimizations | |
259 | e.g. TLS descriptors or optimized TLS access for POWER (@code{DT_PPC64_OPT} | |
260 | and @code{DT_PPC_OPT}). In order to make the best use of such optimizations | |
261 | the value should be as many bytes as would be required to hold all TLS | |
262 | variables in all dynamic loaded shared libraries. The value cannot be known | |
263 | by the dynamic loader because it doesn't know the expected set of shared | |
264 | libraries which will be loaded. The existing static TLS space cannot be | |
265 | changed once allocated at process startup. The default allocation of | |
266 | optional static TLS is 512 bytes and is allocated in every thread. | |
267 | @end deftp | |
268 | ||
269 | ||
07ed18d2 RA |
270 | @node Elision Tunables |
271 | @section Elision Tunables | |
272 | @cindex elision tunables | |
273 | @cindex tunables, elision | |
274 | ||
275 | @deftp {Tunable namespace} glibc.elision | |
276 | Contended locks are usually slow and can lead to performance and scalability | |
277 | issues in multithread code. Lock elision will use memory transactions to under | |
278 | certain conditions, to elide locks and improve performance. | |
279 | Elision behavior can be modified by setting the following tunables in | |
280 | the @code{elision} namespace: | |
281 | @end deftp | |
282 | ||
283 | @deftp Tunable glibc.elision.enable | |
284 | The @code{glibc.elision.enable} tunable enables lock elision if the feature is | |
285 | supported by the hardware. If elision is not supported by the hardware this | |
286 | tunable has no effect. | |
287 | ||
288 | Elision tunables are supported for 64-bit Intel, IBM POWER, and z System | |
289 | architectures. | |
290 | @end deftp | |
291 | ||
292 | @deftp Tunable glibc.elision.skip_lock_busy | |
293 | The @code{glibc.elision.skip_lock_busy} tunable sets how many times to use a | |
294 | non-transactional lock after a transactional failure has occurred because the | |
295 | lock is already acquired. Expressed in number of lock acquisition attempts. | |
296 | ||
297 | The default value of this tunable is @samp{3}. | |
298 | @end deftp | |
299 | ||
300 | @deftp Tunable glibc.elision.skip_lock_internal_abort | |
301 | The @code{glibc.elision.skip_lock_internal_abort} tunable sets how many times | |
302 | the thread should avoid using elision if a transaction aborted for any reason | |
303 | other than a different thread's memory accesses. Expressed in number of lock | |
304 | acquisition attempts. | |
305 | ||
306 | The default value of this tunable is @samp{3}. | |
307 | @end deftp | |
308 | ||
309 | @deftp Tunable glibc.elision.skip_lock_after_retries | |
310 | The @code{glibc.elision.skip_lock_after_retries} tunable sets how many times | |
311 | to try to elide a lock with transactions, that only failed due to a different | |
312 | thread's memory accesses, before falling back to regular lock. | |
313 | Expressed in number of lock elision attempts. | |
314 | ||
315 | This tunable is supported only on IBM POWER, and z System architectures. | |
316 | ||
317 | The default value of this tunable is @samp{3}. | |
318 | @end deftp | |
319 | ||
320 | @deftp Tunable glibc.elision.tries | |
321 | The @code{glibc.elision.tries} sets how many times to retry elision if there is | |
322 | chance for the transaction to finish execution e.g., it wasn't | |
323 | aborted due to the lock being already acquired. If elision is not supported | |
324 | by the hardware this tunable is set to @samp{0} to avoid retries. | |
325 | ||
326 | The default value of this tunable is @samp{3}. | |
327 | @end deftp | |
328 | ||
329 | @deftp Tunable glibc.elision.skip_trylock_internal_abort | |
330 | The @code{glibc.elision.skip_trylock_internal_abort} tunable sets how many | |
331 | times the thread should avoid trying the lock if a transaction aborted due to | |
332 | reasons other than a different thread's memory accesses. Expressed in number | |
333 | of try lock attempts. | |
334 | ||
335 | The default value of this tunable is @samp{3}. | |
336 | @end deftp | |
337 | ||
6310e6be KW |
338 | @node POSIX Thread Tunables |
339 | @section POSIX Thread Tunables | |
340 | @cindex pthread mutex tunables | |
341 | @cindex thread mutex tunables | |
342 | @cindex mutex tunables | |
343 | @cindex tunables thread mutex | |
344 | ||
345 | @deftp {Tunable namespace} glibc.pthread | |
346 | The behavior of POSIX threads can be tuned to gain performance improvements | |
347 | according to specific hardware capabilities and workload characteristics by | |
348 | setting the following tunables in the @code{pthread} namespace: | |
349 | @end deftp | |
350 | ||
351 | @deftp Tunable glibc.pthread.mutex_spin_count | |
352 | The @code{glibc.pthread.mutex_spin_count} tunable sets the maximum number of times | |
353 | a thread should spin on the lock before calling into the kernel to block. | |
354 | Adaptive spin is used for mutexes initialized with the | |
355 | @code{PTHREAD_MUTEX_ADAPTIVE_NP} GNU extension. It affects both | |
356 | @code{pthread_mutex_lock} and @code{pthread_mutex_timedlock}. | |
357 | ||
358 | The thread spins until either the maximum spin count is reached or the lock | |
359 | is acquired. | |
360 | ||
361 | The default value of this tunable is @samp{100}. | |
362 | @end deftp | |
363 | ||
ea9b0ecb SP |
364 | @node Hardware Capability Tunables |
365 | @section Hardware Capability Tunables | |
366 | @cindex hardware capability tunables | |
367 | @cindex hwcap tunables | |
368 | @cindex tunables, hwcap | |
03feacb5 L |
369 | @cindex hwcaps tunables |
370 | @cindex tunables, hwcaps | |
905947c3 L |
371 | @cindex data_cache_size tunables |
372 | @cindex tunables, data_cache_size | |
373 | @cindex shared_cache_size tunables | |
374 | @cindex tunables, shared_cache_size | |
375 | @cindex non_temporal_threshold tunables | |
376 | @cindex tunables, non_temporal_threshold | |
ea9b0ecb | 377 | |
dce452dc | 378 | @deftp {Tunable namespace} glibc.cpu |
ea9b0ecb | 379 | Behavior of @theglibc{} can be tuned to assume specific hardware capabilities |
dce452dc | 380 | by setting the following tunables in the @code{cpu} namespace: |
ea9b0ecb SP |
381 | @end deftp |
382 | ||
dce452dc | 383 | @deftp Tunable glibc.cpu.hwcap_mask |
ea9b0ecb SP |
384 | This tunable supersedes the @env{LD_HWCAP_MASK} environment variable and is |
385 | identical in features. | |
386 | ||
28c3f14f | 387 | The @code{AT_HWCAP} key in the Auxiliary Vector specifies instruction set |
ea9b0ecb | 388 | extensions available in the processor at runtime for some architectures. The |
dce452dc | 389 | @code{glibc.cpu.hwcap_mask} tunable allows the user to mask out those |
ea9b0ecb SP |
390 | capabilities at runtime, thus disabling use of those extensions. |
391 | @end deftp | |
905947c3 | 392 | |
dce452dc SP |
393 | @deftp Tunable glibc.cpu.hwcaps |
394 | The @code{glibc.cpu.hwcaps=-xxx,yyy,-zzz...} tunable allows the user to | |
905947c3 L |
395 | enable CPU/ARCH feature @code{yyy}, disable CPU/ARCH feature @code{xxx} |
396 | and @code{zzz} where the feature name is case-sensitive and has to match | |
397 | the ones in @code{sysdeps/x86/cpu-features.h}. | |
398 | ||
399 | This tunable is specific to i386 and x86-64. | |
400 | @end deftp | |
401 | ||
dce452dc SP |
402 | @deftp Tunable glibc.cpu.cached_memopt |
403 | The @code{glibc.cpu.cached_memopt=[0|1]} tunable allows the user to | |
c9cd7b0c AZ |
404 | enable optimizations recommended for cacheable memory. If set to |
405 | @code{1}, @theglibc{} assumes that the process memory image consists | |
406 | of cacheable (non-device) memory only. The default, @code{0}, | |
407 | indicates that the process may use device memory. | |
408 | ||
409 | This tunable is specific to powerpc, powerpc64 and powerpc64le. | |
410 | @end deftp | |
411 | ||
dce452dc SP |
412 | @deftp Tunable glibc.cpu.name |
413 | The @code{glibc.cpu.name=xxx} tunable allows the user to tell @theglibc{} to | |
28cfa3a4 | 414 | assume that the CPU is @code{xxx} where xxx may have one of these values: |
9c9ec581 | 415 | @code{generic}, @code{falkor}, @code{thunderxt88}, @code{thunderx2t99}, |
0db8e7b3 | 416 | @code{thunderx2t99p1}, @code{ares}, @code{emag}, @code{kunpeng}. |
28cfa3a4 SP |
417 | |
418 | This tunable is specific to aarch64. | |
419 | @end deftp | |
420 | ||
dce452dc SP |
421 | @deftp Tunable glibc.cpu.x86_data_cache_size |
422 | The @code{glibc.cpu.x86_data_cache_size} tunable allows the user to set | |
905947c3 L |
423 | data cache size in bytes for use in memory and string routines. |
424 | ||
425 | This tunable is specific to i386 and x86-64. | |
426 | @end deftp | |
427 | ||
dce452dc SP |
428 | @deftp Tunable glibc.cpu.x86_shared_cache_size |
429 | The @code{glibc.cpu.x86_shared_cache_size} tunable allows the user to | |
905947c3 L |
430 | set shared cache size in bytes for use in memory and string routines. |
431 | @end deftp | |
432 | ||
dce452dc SP |
433 | @deftp Tunable glibc.cpu.x86_non_temporal_threshold |
434 | The @code{glibc.cpu.x86_non_temporal_threshold} tunable allows the user | |
905947c3 L |
435 | to set threshold in bytes for non temporal store. |
436 | ||
437 | This tunable is specific to i386 and x86-64. | |
438 | @end deftp | |
6d90776d | 439 | |
3f4b61a0 L |
440 | @deftp Tunable glibc.cpu.x86_rep_movsb_threshold |
441 | The @code{glibc.cpu.x86_rep_movsb_threshold} tunable allows the user to | |
442 | set threshold in bytes to start using "rep movsb". The value must be | |
443 | greater than zero, and currently defaults to 2048 bytes. | |
444 | ||
445 | This tunable is specific to i386 and x86-64. | |
446 | @end deftp | |
447 | ||
448 | @deftp Tunable glibc.cpu.x86_rep_stosb_threshold | |
449 | The @code{glibc.cpu.x86_rep_stosb_threshold} tunable allows the user to | |
450 | set threshold in bytes to start using "rep stosb". The value must be | |
451 | greater than zero, and currently defaults to 2048 bytes. | |
452 | ||
453 | This tunable is specific to i386 and x86-64. | |
454 | @end deftp | |
455 | ||
dce452dc SP |
456 | @deftp Tunable glibc.cpu.x86_ibt |
457 | The @code{glibc.cpu.x86_ibt} tunable allows the user to control how | |
6d90776d L |
458 | indirect branch tracking (IBT) should be enabled. Accepted values are |
459 | @code{on}, @code{off}, and @code{permissive}. @code{on} always turns | |
460 | on IBT regardless of whether IBT is enabled in the executable and its | |
461 | dependent shared libraries. @code{off} always turns off IBT regardless | |
462 | of whether IBT is enabled in the executable and its dependent shared | |
463 | libraries. @code{permissive} is the same as the default which disables | |
464 | IBT on non-CET executables and shared libraries. | |
465 | ||
466 | This tunable is specific to i386 and x86-64. | |
467 | @end deftp | |
468 | ||
dce452dc SP |
469 | @deftp Tunable glibc.cpu.x86_shstk |
470 | The @code{glibc.cpu.x86_shstk} tunable allows the user to control how | |
6d90776d L |
471 | the shadow stack (SHSTK) should be enabled. Accepted values are |
472 | @code{on}, @code{off}, and @code{permissive}. @code{on} always turns on | |
473 | SHSTK regardless of whether SHSTK is enabled in the executable and its | |
474 | dependent shared libraries. @code{off} always turns off SHSTK regardless | |
475 | of whether SHSTK is enabled in the executable and its dependent shared | |
476 | libraries. @code{permissive} changes how dlopen works on non-CET shared | |
477 | libraries. By default, when SHSTK is enabled, dlopening a non-CET shared | |
478 | library returns an error. With @code{permissive}, it turns off SHSTK | |
479 | instead. | |
480 | ||
481 | This tunable is specific to i386 and x86-64. | |
482 | @end deftp |