SPEC CPU®2026 Flag Description - Polystack Platform settings
Operating System Tuning Parameters
ulimit
This sets user limits of system-wide resources and can set the stack size to n kbytes,
or unlimited to allow the stack size to grow without limit. Common ulimit commands may include:
- ulimit -s [n | unlimited]: Set the stack size to n kbytes, or unlimited to allow the stack
size to grow without limit.
- ulimit -l (number): Set the maximum size that can be locked into memory.
Kernel Parameters
The following Linux Kernel parameters (run as 'root') can be used to optimize performance.
More information on standard Linux kernal parameters may be found at:
dirty_ratio
This sets the percentage of total system memory that can be filled with dirty pages before
everything must get committed to disk. It helps manage memory usage by controlling how
much dirty memory can accumulate before the system starts to write it back to disk; excessive
accumulation of dirty memory can lead to performance issues or system instability.
The command "sysctl -w vm.dirty_ratio=8" sets the dirty cache to 8% of memory.
drop_caches
This instructs the kernel free the file system page cache, and reclaimable slab objects such as
dentries and inodes, which can help free up memory.
Possible settings are:
- 1: Drops page cache
- 2: Drops dentries and inodes
- 3: Drops page cache, dentries, and inodes
The command "echo 3> /proc/sys/vm/drop_caches" is used to free up the all filesystem page cache.
randomize_va_space
This setting can be used to select the type of process address space layout randomization (ASLR) used on
the system. Disabling ASLR can make process execution more deterministic and runtimes more consistent.
Possible settings are:
- 0: Turn process address space randomization off.
- 1: Randomize addresses of mmap base, stack, and VDSO pages.
- 2: Additionally randomize the heap.
The command "sysctl -w kernel.randomize_va_space=0" is used to reduce run-to-run variability.
swappiness
This setting is used to define the rough relative cost of swapping and filesystem paging as value
from 1 to 100 (default 60). It determines the balance between swapping out process memory and dropping
pages from the page cache. A value of 1 will avoid swapping until memory is very low and swapping to
disk is absolutely necessary. A value of 100 treats swapping and filesystem paging as equally costly
and will cause the kernel to swap out inactive processes frequently in favor of file system performance,
resulting in large disk cache sizes.
The command "sysctl -w vm.swappiness=1" is used to minimize swapping.
Transparent Hugepages (THP)
THP is an abstraction layer that uses huge pages to back virtual memory automatically, including
promotion and demotion of page sizes. It can improve performance by reducing page faults and TLB
misses. Huge pages increase the memory page size from 4 KB to 2 MB.
The command "echo option > /sys/kernel/mm/transparent_hugepage/enabled" is used to control THP usage.
Common values for option are:
- always: enable THP usage. (default)
- madvise: enable THP only insied regions marked MADV_HUGEPAGE using madvise(3).
- never: disable THP usage.
The command "echo option > /sys/kernel/mm/transparent_hugepage/defrag" is used to limit defrag efforts in the
VM to generate anonymous hugepates in case they are not immediately free.
Common values for option are:
- always: An allocation requesting THP when none are available will stall until some are made.
- defer: An allocation requesting THP when none are available get normal pages while requesting THP creation in the background.
- defer+madvise: Acts like "always", but only for allocations in regions marked MADV_HUGEPAGE using madvise(3); for all other regions it's like "defer".
- madvise: Acts like "always", but only for allocations in regions marked MADV_HUGEPAGE using madvise(3). (Default)
- never: If no THP are available to satisfy a request, do not attempt to make any.
The command "echo option > /sys/kernel/mm/transparent_hugepage/shmem_enabled" is used to affect
the allocation policy of shared memory (shmem or tmpfs) mounts.
Common values for option are:
- advise: Attempt to allocate huge pages based on application advice.
- always: Always attempt to allocate huge pages for shared memory.
- deny: Prevent the allocation of huge pages shared memory mounts. (Emergency use)
- force: Force the allocation of huge pages on for all mounts. (Useful for testing)
- never: Do not allocate huge pages for shared memory. (Default)
- within_size: Allocate huge pages only if the request size is within a specified limit.
zone_reclaim-mode
Zone reclaim controls how aggressively the kernel reclaims free pages when a zone runs out of memory.
Reclaiming a page can be more beneficial than taking the performance penalties that are associated
with allocating a page on a remote zone, especially for systems with Non-Uniform Memory Access (NUMA).
Possible settings:
- 0: No zone reclaim (default).
- 1: Enables zone reclaim - recommended for NUMA systems.
- 2: Enables zone reclaim and allows writing dirty pages during reclaim.
- 4: Allows unmapping of mapped file pages during reclaim.
- 7: Enables all reclaim behaviours (zone reclaim, writing dirty pages, and unmapping).
The command "sysctl -w vm.zone_reclaim_mode=1" is used to reclaim memory more efficiently within
the same node before accessing memory from other nodes.
Firmware / BIOS / Microcode Settings
C-States
Controls processor low-power idle states (C-states).
- Enabled: The processor may enter power-saving idle states when inactive.
- Disabled: The processor stays in the active C0 state to reduce wakeup latencies.
Default: Enabled
Fan Control
Selects system cooling fan speed profile.
- Standard: Fan speed adjusts dynamically based on thermal load.
- Full speed mode: System fans run at maximum speed continuously to ensure optimal thermal performance.
Default: Standard
NUMA nodes per socket
Controls the number of desired NUMA nodes per populated processor socket.
- NPS0: All memory channels are interleaved across the entire system.
- NPS1: All memory channels on a socket are interleaved into one NUMA domain.
- NPS2: Memory channels on a socket are split into two NUMA domains.
- NPS4: Memory channels on a socket are split into four NUMA domains.
Default: NPS1.
Virtualization Technology (AMD-V)
Enables or disables hardware virtualization extensions provided by AMD processors.
- Enabled: Processor virtualization features are available to the OS/hypervisor.
- Disabled: Processor virtualization features are hidden from the OS.
Default: Enabled