Blame manual/tunables.texi

Packit Service 82fcde
@node Tunables
Packit Service 82fcde
@c @node Tunables, , Internal Probes, Top
Packit Service 82fcde
@c %MENU% Tunable switches to alter libc internal behavior
Packit Service 82fcde
@chapter Tunables
Packit Service 82fcde
@cindex tunables
Packit Service 82fcde
Packit Service 82fcde
@dfn{Tunables} are a feature in @theglibc{} that allows application authors and
Packit Service 82fcde
distribution maintainers to alter the runtime library behavior to match
Packit Service 82fcde
their workload. These are implemented as a set of switches that may be
Packit Service 82fcde
modified in different ways. The current default method to do this is via
Packit Service 82fcde
the @env{GLIBC_TUNABLES} environment variable by setting it to a string
Packit Service 82fcde
of colon-separated @var{name}=@var{value} pairs.  For example, the following
Packit Service 82fcde
example enables malloc checking and sets the malloc trim threshold to 128
Packit Service 82fcde
bytes:
Packit Service 82fcde
Packit Service 82fcde
@example
Packit Service 82fcde
GLIBC_TUNABLES=glibc.malloc.trim_threshold=128:glibc.malloc.check=3
Packit Service 82fcde
export GLIBC_TUNABLES
Packit Service 82fcde
@end example
Packit Service 82fcde
Packit Service 82fcde
Tunables are not part of the @glibcadj{} stable ABI, and they are
Packit Service 82fcde
subject to change or removal across releases.  Additionally, the method to
Packit Service 82fcde
modify tunable values may change between releases and across distributions.
Packit Service 82fcde
It is possible to implement multiple `frontends' for the tunables allowing
Packit Service 82fcde
distributions to choose their preferred method at build time.
Packit Service 82fcde
Packit Service 82fcde
Finally, the set of tunables available may vary between distributions as
Packit Service 82fcde
the tunables feature allows distributions to add their own tunables under
Packit Service 82fcde
their own namespace.
Packit Service 82fcde
Packit Service 82fcde
@menu
Packit Service 82fcde
* Tunable names::  The structure of a tunable name
Packit Service 82fcde
* Memory Allocation Tunables::  Tunables in the memory allocation subsystem
Packit Service 82fcde
* Elision Tunables::  Tunables in elision subsystem
Packit Service 82fcde
* Hardware Capability Tunables::  Tunables that modify the hardware
Packit Service 82fcde
				  capabilities seen by @theglibc{}
Packit Service 82fcde
@end menu
Packit Service 82fcde
Packit Service 82fcde
@node Tunable names
Packit Service 82fcde
@section Tunable names
Packit Service 82fcde
@cindex Tunable names
Packit Service 82fcde
@cindex Tunable namespaces
Packit Service 82fcde
Packit Service 82fcde
A tunable name is split into three components, a top namespace, a tunable
Packit Service 82fcde
namespace and the tunable name. The top namespace for tunables implemented in
Packit Service 82fcde
@theglibc{} is @code{glibc}. Distributions that choose to add custom tunables
Packit Service 82fcde
in their maintained versions of @theglibc{} may choose to do so under their own
Packit Service 82fcde
top namespace.
Packit Service 82fcde
Packit Service 82fcde
The tunable namespace is a logical grouping of tunables in a single
Packit Service 82fcde
module. This currently holds no special significance, although that may
Packit Service 82fcde
change in the future.
Packit Service 82fcde
Packit Service 82fcde
The tunable name is the actual name of the tunable. It is possible that
Packit Service 82fcde
different tunable namespaces may have tunables within them that have the
Packit Service 82fcde
same name, likewise for top namespaces. Hence, we only support
Packit Service 82fcde
identification of tunables by their full name, i.e. with the top
Packit Service 82fcde
namespace, tunable namespace and tunable name, separated by periods.
Packit Service 82fcde
Packit Service 82fcde
@node Memory Allocation Tunables
Packit Service 82fcde
@section Memory Allocation Tunables
Packit Service 82fcde
@cindex memory allocation tunables
Packit Service 82fcde
@cindex malloc tunables
Packit Service 82fcde
@cindex tunables, malloc
Packit Service 82fcde
Packit Service 82fcde
@deftp {Tunable namespace} glibc.malloc
Packit Service 82fcde
Memory allocation behavior can be modified by setting any of the
Packit Service 82fcde
following tunables in the @code{malloc} namespace:
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.check
Packit Service 82fcde
This tunable supersedes the @env{MALLOC_CHECK_} environment variable and is
Packit Service 82fcde
identical in features.
Packit Service 82fcde
Packit Service 82fcde
Setting this tunable to a non-zero value enables a special (less
Packit Service 82fcde
efficient) memory allocator for the malloc family of functions that is
Packit Service 82fcde
designed to be tolerant against simple errors such as double calls of
Packit Service 82fcde
free with the same argument, or overruns of a single byte (off-by-one
Packit Service 82fcde
bugs). Not all such errors can be protected against, however, and memory
Packit Service 82fcde
leaks can result.  Any detected heap corruption results in immediate
Packit Service 82fcde
termination of the process.
Packit Service 82fcde
Packit Service 82fcde
Like @env{MALLOC_CHECK_}, @code{glibc.malloc.check} has a problem in that it
Packit Service 82fcde
diverges from normal program behavior by writing to @code{stderr}, which could
Packit Service 82fcde
by exploited in SUID and SGID binaries.  Therefore, @code{glibc.malloc.check}
Packit Service 82fcde
is disabled by default for SUID and SGID binaries.  This can be enabled again
Packit Service 82fcde
by the system administrator by adding a file @file{/etc/suid-debug}; the
Packit Service 82fcde
content of the file could be anything or even empty.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.top_pad
Packit Service 82fcde
This tunable supersedes the @env{MALLOC_TOP_PAD_} environment variable and is
Packit Service 82fcde
identical in features.
Packit Service 82fcde
Packit Service 82fcde
This tunable determines the amount of extra memory in bytes to obtain from the
Packit Service 82fcde
system when any of the arenas need to be extended.  It also specifies the
Packit Service 82fcde
number of bytes to retain when shrinking any of the arenas.  This provides the
Packit Service 82fcde
necessary hysteresis in heap size such that excessive amounts of system calls
Packit Service 82fcde
can be avoided.
Packit Service 82fcde
Packit Service 82fcde
The default value of this tunable is @samp{0}.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.perturb
Packit Service 82fcde
This tunable supersedes the @env{MALLOC_PERTURB_} environment variable and is
Packit Service 82fcde
identical in features.
Packit Service 82fcde
Packit Service 82fcde
If set to a non-zero value, memory blocks are initialized with values depending
Packit Service 82fcde
on some low order bits of this tunable when they are allocated (except when
Packit Service 82fcde
allocated by calloc) and freed.  This can be used to debug the use of
Packit Service 82fcde
uninitialized or freed heap memory. Note that this option does not guarantee
Packit Service 82fcde
that the freed block will have any specific values. It only guarantees that the
Packit Service 82fcde
content the block had before it was freed will be overwritten.
Packit Service 82fcde
Packit Service 82fcde
The default value of this tunable is @samp{0}.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.mmap_threshold
Packit Service 82fcde
This tunable supersedes the @env{MALLOC_MMAP_THRESHOLD_} environment variable
Packit Service 82fcde
and is identical in features.
Packit Service 82fcde
Packit Service 82fcde
When this tunable is set, all chunks larger than this value in bytes are
Packit Service 82fcde
allocated outside the normal heap, using the @code{mmap} system call. This way
Packit Service 82fcde
it is guaranteed that the memory for these chunks can be returned to the system
Packit Service 82fcde
on @code{free}. Note that requests smaller than this threshold might still be
Packit Service 82fcde
allocated via @code{mmap}.
Packit Service 82fcde
Packit Service 82fcde
If this tunable is not set, the default value is set to @samp{131072} bytes and
Packit Service 82fcde
the threshold is adjusted dynamically to suit the allocation patterns of the
Packit Service 82fcde
program.  If the tunable is set, the dynamic adjustment is disabled and the
Packit Service 82fcde
value is set as static.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.trim_threshold
Packit Service 82fcde
This tunable supersedes the @env{MALLOC_TRIM_THRESHOLD_} environment variable
Packit Service 82fcde
and is identical in features.
Packit Service 82fcde
Packit Service 82fcde
The value of this tunable is the minimum size (in bytes) of the top-most,
Packit Service 82fcde
releasable chunk in an arena that will trigger a system call in order to return
Packit Service 82fcde
memory to the system from that arena.
Packit Service 82fcde
Packit Service 82fcde
If this tunable is not set, the default value is set as 128 KB and the
Packit Service 82fcde
threshold is adjusted dynamically to suit the allocation patterns of the
Packit Service 82fcde
program.  If the tunable is set, the dynamic adjustment is disabled and the
Packit Service 82fcde
value is set as static.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.mmap_max
Packit Service 82fcde
This tunable supersedes the @env{MALLOC_MMAP_MAX_} environment variable and is
Packit Service 82fcde
identical in features.
Packit Service 82fcde
Packit Service 82fcde
The value of this tunable is maximum number of chunks to allocate with
Packit Service 82fcde
@code{mmap}.  Setting this to zero disables all use of @code{mmap}.
Packit Service 82fcde
Packit Service 82fcde
The default value of this tunable is @samp{65536}.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.arena_test
Packit Service 82fcde
This tunable supersedes the @env{MALLOC_ARENA_TEST} environment variable and is
Packit Service 82fcde
identical in features.
Packit Service 82fcde
Packit Service 82fcde
The @code{glibc.malloc.arena_test} tunable specifies the number of arenas that
Packit Service 82fcde
can be created before the test on the limit to the number of arenas is
Packit Service 82fcde
conducted.  The value is ignored if @code{glibc.malloc.arena_max} is set.
Packit Service 82fcde
Packit Service 82fcde
The default value of this tunable is 2 for 32-bit systems and 8 for 64-bit
Packit Service 82fcde
systems.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.arena_max
Packit Service 82fcde
This tunable supersedes the @env{MALLOC_ARENA_MAX} environment variable and is
Packit Service 82fcde
identical in features.
Packit Service 82fcde
Packit Service 82fcde
This tunable sets the number of arenas to use in a process regardless of the
Packit Service 82fcde
number of cores in the system.
Packit Service 82fcde
Packit Service 82fcde
The default value of this tunable is @code{0}, meaning that the limit on the
Packit Service 82fcde
number of arenas is determined by the number of CPU cores online.  For 32-bit
Packit Service 82fcde
systems the limit is twice the number of cores online and on 64-bit systems, it
Packit Service 82fcde
is 8 times the number of cores online.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.tcache_max
Packit Service 82fcde
The maximum size of a request (in bytes) which may be met via the
Packit Service 82fcde
per-thread cache.  The default (and maximum) value is 1032 bytes on
Packit Service 82fcde
64-bit systems and 516 bytes on 32-bit systems.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.tcache_count
Packit Service 82fcde
The maximum number of chunks of each size to cache. The default is 7.
Packit Service b0b361
The upper limit is 65535.  If set to zero, the per-thread cache is effectively
Packit Service fcd93a
disabled.
Packit Service 82fcde
Packit Service 82fcde
The approximate maximum overhead of the per-thread cache is thus equal
Packit Service 82fcde
to the number of bins times the chunk count in each bin times the size
Packit Service 82fcde
of each chunk.  With defaults, the approximate maximum overhead of the
Packit Service 82fcde
per-thread cache is approximately 236 KB on 64-bit systems and 118 KB
Packit Service 82fcde
on 32-bit systems.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.malloc.tcache_unsorted_limit
Packit Service 82fcde
When the user requests memory and the request cannot be met via the
Packit Service 82fcde
per-thread cache, the arenas are used to meet the request.  At this
Packit Service 82fcde
time, additional chunks will be moved from existing arena lists to
Packit Service 82fcde
pre-fill the corresponding cache.  While copies from the fastbins,
Packit Service 82fcde
smallbins, and regular bins are bounded and predictable due to the bin
Packit Service 82fcde
sizes, copies from the unsorted bin are not bounded, and incur
Packit Service 82fcde
additional time penalties as they need to be sorted as they're
Packit Service 82fcde
scanned.  To make scanning the unsorted list more predictable and
Packit Service 82fcde
bounded, the user may set this tunable to limit the number of chunks
Packit Service 82fcde
that are scanned from the unsorted list while searching for chunks to
Packit Service 82fcde
pre-fill the per-thread cache with.  The default, or when set to zero,
Packit Service 82fcde
is no limit.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 194106
@deftp Tunable glibc.malloc.mxfast
Packit Service 194106
One of the optimizations malloc uses is to maintain a series of ``fast
Packit Service 194106
bins'' that hold chunks up to a specific size.  The default and
Packit Service 194106
maximum size which may be held this way is 80 bytes on 32-bit systems
Packit Service 194106
or 160 bytes on 64-bit systems.  Applications which value size over
Packit Service 194106
speed may choose to reduce the size of requests which are serviced
Packit Service 194106
from fast bins with this tunable.  Note that the value specified
Packit Service 194106
includes malloc's internal overhead, which is normally the size of one
Packit Service 194106
pointer, so add 4 on 32-bit systems or 8 on 64-bit systems to the size
Packit Service 194106
passed to @code{malloc} for the largest bin size to enable.
Packit Service 194106
@end deftp
Packit Service 194106
Packit Service 82fcde
@node Elision Tunables
Packit Service 82fcde
@section Elision Tunables
Packit Service 82fcde
@cindex elision tunables
Packit Service 82fcde
@cindex tunables, elision
Packit Service 82fcde
Packit Service 82fcde
@deftp {Tunable namespace} glibc.elision
Packit Service 82fcde
Contended locks are usually slow and can lead to performance and scalability
Packit Service 82fcde
issues in multithread code. Lock elision will use memory transactions to under
Packit Service 82fcde
certain conditions, to elide locks and improve performance.
Packit Service 82fcde
Elision behavior can be modified by setting the following tunables in
Packit Service 82fcde
the @code{elision} namespace:
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.elision.enable
Packit Service 82fcde
The @code{glibc.elision.enable} tunable enables lock elision if the feature is
Packit Service 82fcde
supported by the hardware.  If elision is not supported by the hardware this
Packit Service 82fcde
tunable has no effect.
Packit Service 82fcde
Packit Service 82fcde
Elision tunables are supported for 64-bit Intel, IBM POWER, and z System
Packit Service 82fcde
architectures.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.elision.skip_lock_busy
Packit Service 82fcde
The @code{glibc.elision.skip_lock_busy} tunable sets how many times to use a
Packit Service 82fcde
non-transactional lock after a transactional failure has occurred because the
Packit Service 82fcde
lock is already acquired.  Expressed in number of lock acquisition attempts.
Packit Service 82fcde
Packit Service 82fcde
The default value of this tunable is @samp{3}.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.elision.skip_lock_internal_abort
Packit Service 82fcde
The @code{glibc.elision.skip_lock_internal_abort} tunable sets how many times
Packit Service 82fcde
the thread should avoid using elision if a transaction aborted for any reason
Packit Service 82fcde
other than a different thread's memory accesses.  Expressed in number of lock
Packit Service 82fcde
acquisition attempts.
Packit Service 82fcde
Packit Service 82fcde
The default value of this tunable is @samp{3}.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.elision.skip_lock_after_retries
Packit Service 82fcde
The @code{glibc.elision.skip_lock_after_retries} tunable sets how many times
Packit Service 82fcde
to try to elide a lock with transactions, that only failed due to a different
Packit Service 82fcde
thread's memory accesses, before falling back to regular lock.
Packit Service 82fcde
Expressed in number of lock elision attempts.
Packit Service 82fcde
Packit Service 82fcde
This tunable is supported only on IBM POWER, and z System architectures.
Packit Service 82fcde
Packit Service 82fcde
The default value of this tunable is @samp{3}.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.elision.tries
Packit Service 82fcde
The @code{glibc.elision.tries} sets how many times to retry elision if there is
Packit Service 82fcde
chance for the transaction to finish execution e.g., it wasn't
Packit Service 82fcde
aborted due to the lock being already acquired.  If elision is not supported
Packit Service 82fcde
by the hardware this tunable is set to @samp{0} to avoid retries.
Packit Service 82fcde
Packit Service 82fcde
The default value of this tunable is @samp{3}.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.elision.skip_trylock_internal_abort
Packit Service 82fcde
The @code{glibc.elision.skip_trylock_internal_abort} tunable sets how many
Packit Service 82fcde
times the thread should avoid trying the lock if a transaction aborted due to
Packit Service 82fcde
reasons other than a different thread's memory accesses.  Expressed in number
Packit Service 82fcde
of try lock attempts.
Packit Service 82fcde
Packit Service 82fcde
The default value of this tunable is @samp{3}.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@node Hardware Capability Tunables
Packit Service 82fcde
@section Hardware Capability Tunables
Packit Service 82fcde
@cindex hardware capability tunables
Packit Service 82fcde
@cindex hwcap tunables
Packit Service 82fcde
@cindex tunables, hwcap
Packit Service 82fcde
@cindex hwcaps tunables
Packit Service 82fcde
@cindex tunables, hwcaps
Packit Service 82fcde
@cindex data_cache_size tunables
Packit Service 82fcde
@cindex tunables, data_cache_size
Packit Service 82fcde
@cindex shared_cache_size tunables
Packit Service 82fcde
@cindex tunables, shared_cache_size
Packit Service 82fcde
@cindex non_temporal_threshold tunables
Packit Service 82fcde
@cindex tunables, non_temporal_threshold
Packit Service 82fcde
Packit Service 82fcde
@deftp {Tunable namespace} glibc.tune
Packit Service 82fcde
Behavior of @theglibc{} can be tuned to assume specific hardware capabilities
Packit Service 82fcde
by setting the following tunables in the @code{tune} namespace:
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.tune.hwcap_mask
Packit Service 82fcde
This tunable supersedes the @env{LD_HWCAP_MASK} environment variable and is
Packit Service 82fcde
identical in features.
Packit Service 82fcde
Packit Service 82fcde
The @code{AT_HWCAP} key in the Auxiliary Vector specifies instruction set
Packit Service 82fcde
extensions available in the processor at runtime for some architectures.  The
Packit Service 82fcde
@code{glibc.tune.hwcap_mask} tunable allows the user to mask out those
Packit Service 82fcde
capabilities at runtime, thus disabling use of those extensions.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.tune.hwcaps
Packit Service 82fcde
The @code{glibc.tune.hwcaps=-xxx,yyy,-zzz...} tunable allows the user to
Packit Service 82fcde
enable CPU/ARCH feature @code{yyy}, disable CPU/ARCH feature @code{xxx}
Packit Service 82fcde
and @code{zzz} where the feature name is case-sensitive and has to match
Packit Service 82fcde
the ones in @code{sysdeps/x86/cpu-features.h}.
Packit Service 82fcde
Packit Service 82fcde
This tunable is specific to i386 and x86-64.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.tune.cached_memopt
Packit Service 82fcde
The @code{glibc.tune.cached_memopt=[0|1]} tunable allows the user to
Packit Service 82fcde
enable optimizations recommended for cacheable memory.  If set to
Packit Service 82fcde
@code{1}, @theglibc{} assumes that the process memory image consists
Packit Service 82fcde
of cacheable (non-device) memory only.  The default, @code{0},
Packit Service 82fcde
indicates that the process may use device memory.
Packit Service 82fcde
Packit Service 82fcde
This tunable is specific to powerpc, powerpc64 and powerpc64le.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.tune.cpu
Packit Service 82fcde
The @code{glibc.tune.cpu=xxx} tunable allows the user to tell @theglibc{} to
Packit Service 82fcde
assume that the CPU is @code{xxx} where xxx may have one of these values:
Packit Service 82fcde
@code{generic}, @code{falkor}, @code{thunderxt88}, @code{thunderx2t99},
Packit Service 82fcde
@code{thunderx2t99p1}.
Packit Service 82fcde
Packit Service 82fcde
This tunable is specific to aarch64.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.tune.x86_data_cache_size
Packit Service 82fcde
The @code{glibc.tune.x86_data_cache_size} tunable allows the user to set
Packit Service 82fcde
data cache size in bytes for use in memory and string routines.
Packit Service 82fcde
Packit Service 82fcde
This tunable is specific to i386 and x86-64.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.tune.x86_shared_cache_size
Packit Service 82fcde
The @code{glibc.tune.x86_shared_cache_size} tunable allows the user to
Packit Service 82fcde
set shared cache size in bytes for use in memory and string routines.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.tune.x86_non_temporal_threshold
Packit Service 82fcde
The @code{glibc.tune.x86_non_temporal_threshold} tunable allows the user
Packit Service 82fcde
to set threshold in bytes for non temporal store.
Packit Service 82fcde
Packit Service 82fcde
This tunable is specific to i386 and x86-64.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.tune.x86_ibt
Packit Service 82fcde
The @code{glibc.tune.x86_ibt} tunable allows the user to control how
Packit Service 82fcde
indirect branch tracking (IBT) should be enabled.  Accepted values are
Packit Service 82fcde
@code{on}, @code{off}, and @code{permissive}.  @code{on} always turns
Packit Service 82fcde
on IBT regardless of whether IBT is enabled in the executable and its
Packit Service 82fcde
dependent shared libraries.  @code{off} always turns off IBT regardless
Packit Service 82fcde
of whether IBT is enabled in the executable and its dependent shared
Packit Service 82fcde
libraries.  @code{permissive} is the same as the default which disables
Packit Service 82fcde
IBT on non-CET executables and shared libraries.
Packit Service 82fcde
Packit Service 82fcde
This tunable is specific to i386 and x86-64.
Packit Service 82fcde
@end deftp
Packit Service 82fcde
Packit Service 82fcde
@deftp Tunable glibc.tune.x86_shstk
Packit Service 82fcde
The @code{glibc.tune.x86_shstk} tunable allows the user to control how
Packit Service 82fcde
the shadow stack (SHSTK) should be enabled.  Accepted values are
Packit Service 82fcde
@code{on}, @code{off}, and @code{permissive}.  @code{on} always turns on
Packit Service 82fcde
SHSTK regardless of whether SHSTK is enabled in the executable and its
Packit Service 82fcde
dependent shared libraries.  @code{off} always turns off SHSTK regardless
Packit Service 82fcde
of whether SHSTK is enabled in the executable and its dependent shared
Packit Service 82fcde
libraries.  @code{permissive} changes how dlopen works on non-CET shared
Packit Service 82fcde
libraries.  By default, when SHSTK is enabled, dlopening a non-CET shared
Packit Service 82fcde
library returns an error.  With @code{permissive}, it turns off SHSTK
Packit Service 82fcde
instead.
Packit Service 82fcde
Packit Service 82fcde
This tunable is specific to i386 and x86-64.
Packit Service 82fcde
@end deftp