Rate This Document
Findability
Accuracy
Completeness
Readability

Common Configuration Items of ExaGear

Table 1 Common configuration items of ExaGear

Configuration Item

Command Line Parameter

Function

Description

Configuration items of the ExaGear function module

EXAGEAR_USE_OPT

--use_opt <param>

Enables the dynamic secondary optimization.

If "function first" is required, setting "n" can disable this item.

EXAGEAR_OPT_SOCKET

<param> corresponding to --use_opt

Starts the dynamic secondary optimization engine through the exagear-x86_[32|64]-opt.service system service.

The exagear-x86_[32|64]-opt system service must be enabled in advance.

EXAGEAR_OPT_BINARY

<param> corresponding to --use_opt

Starts the dynamic secondary optimization engine through the translator main program.

If EXAGEAR_OPT_SOCKET is left empty, this item takes effect.

EXAGEAR_ENABLE_SW_PROF

--enable-sw-prof

Implements the dynamic secondary optimization through software sampling.

Generally, Statistical Profiling Extension (SPE) is used for hardware sampling.

Unsafe optimizations

EXAGEAR_DISABLE_NATIVE_RETURN_ADDR_OPT

--disable-native-ret-addr-opt

Disables the action of placing the returned native address in the address space of the guest system.

If "function first" is required, setting "y" can disable this item.

EXAGEAR_DISABLE_THP_PREALLOC

--disable-thp-preallocation

Disables memory pre-allocation for blocks that are aligned with huge pages.

If "function first" is required, setting "y" can disable this item.

EXAGEAR_DISABLE_THP_MADVISE

--disable-thp-madvise

Disables the madvise(MADV_HUGEPAGE) mode in all memory page if THP is set to [madvise].

If "function first" is required, setting "y" can disable this item.

EXAGEAR_DISABLE_FLAGS_ON_RET_OPT

--disable-flags-on-call-ret-opt

Disables the optimization on flags of the return instruction.

If "function first" is required, setting "y" can disable this item.

EXAGEAR_DISABLE_JIT_STORE_OPT

--disable-jit-store-opt

Disables the simulation on the JIT write operation by using /proc/self/mem.

If "function first" is required, setting "y" can disable this item.

EXAGEAR_FAST_MATH

--fast-math

Allows faster execution of mathematical calculations. However, it may lead to inaccurate results in some cases.

If "performance first" is required, setting "y" can enable this item.

EXAGEAR_X86_DISABLE_SSE_PRESERVE

--x86-disable-sse-preserve

Specifies that the upper-bit data of the ymm register during SSE instruction translation is not saved when the AVX instruction in enabled.

If "performance first" is required, setting "y" can enable this item.

EXAGEAR_X86_ENABLE_VZEROUPPER

--x86-enable-vzeroupper

Sets the upper bits of the ymm register to 0 during zeroupper instruction translation.

If "function first" is required, setting "y" can enable this item.

Configuration items for guest applications

EXAGEAR_X86_PRECISE_FP

--x86-precise-fp

Enables bitwise precise simulation of x86 floating-point computing.

If "function first" is required, setting "y" can enable this item.

EXAGEAR_X86_PRECISE_80BIT_FP

--x86-precise-80bit-fp

Enables bitwise precise simulation of 80-bit x86 floating-point computing.

If "function first" is required, setting "y" can enable this item.

EXAGEAR_X86_ENABLE_AVX

--x86-enable-avx

Enables AVX simulation.

If "function first" is required, setting "y" can enable this item.

EXAGEAR_X86_ENABLE_AVX512

--x86-enable-avx512

Enables AVX512 simulation.

If "function first" is required, setting "y" can enable this item.

Configuration item of hosts

EXAGEAR_ENABLE_SVE

--enable-sve

Enables the host SVE instruction for translation.

If "performance first" is required, setting "y" can enable this item.

EXAGEAR_ENABLE_SVE512

--enable-sve512

Enables the host SVE512 instruction for translation.

If "performance first" is required, setting "y" can enable this item.

Configuration items of strong memory ordering

EXAGEAR_SMO_MODE

--smo-mode <mode>

Specifies the impact scope of strong memory ordering (default: "fbase").

If "function first" is required, set it to "all".

If "performance first" is required, set it to "fbase".

EXAGEAR_SMO_SEVERITY

--smo-severity <severity>

Specifies the implementation mode of strong memory ordering (default: "smart").

"smart": Memory access instructions irrelevant to strong memory ordering are intelligently identified and redundant memory barriers are removed.

"full": The memory barrier is fully used, and the performance deteriorates significantly. It is used only for debugging.

EXAGEAR_DISABLE_SMO_IN_JIT

--disable-smo-in-jit

Disables the strong memory ordering mode of the JIT code segment.

If "function first" is required, this item can be disabled.

EXAGEAR_SMO_PATTERNS

--smo-patterns=<patterns>

Specifies the list of files that need to be translated in strong memory ordering mode. This parameter is used when SMO_MODE is set to "fbase". File names are separated by commas (,) without spaces (default: "").

The matching rule is any substring of the file name. For example, libmpi.so and libmath.so can be written as EXAGEAR_SMO_PATTERNS="mpi,math".

EXAGEAR_SMO_PATTERNS_EXCL

--smo-patterns-excl=<patterns>

Specifies the list of files that do not need to be translated in strong memory ordering mode. This parameter is used when SMO_MODE is set to "all". File names are separated by commas (,) without spaces (default: "").

The example is the same as above.

EXAGEAR_SMO_CONFIG

--smo-config <config>

Specifies the path of the SMO configuration file.

It is used only for debugging.

EXAGEAR_SMO_LIBC_USE_BLACKLIST

--smo-libc-use-blacklist

Use the strong sequence blocklist for libc.so of version 2.34 or later.

That is, all functions except the built-in blocklist function are in weak order.

EXAGEAR_SMO_DISABLE_LIBC_WARN

--smo-disable-libc-warn

Check whether libc.so of version 2.34 or later contains the ExaGear patch.

If the check fails, an alarm is generated.

Other configuration items

EXAGEAR_FD_HARD_LIMIT

--rlimit-nofile-guest -1,<limit>

Sets the maximum number of file descriptors for an x86 application process.

Specific requirements of x86 applications are adapted.

EXAGEAR_SUPPRESS_ABNORMAL_LOGS

--suppress-abnormal-logs

Specifies whether to enable the information printing.

When the application receives signals such as SIGSEGV, SIGFPE, SIGILL, SIGBUS, SIGTRAP, and SIGABRT and exits, set the value to "y" to disable the printing of related information.

EXAGEAR_DP_TABLE_HASH_SIZE

--dp-table-hash-size <size>

Returns the power value of 2, specifying the size of the ExaGear internal lookup table. The default value is 20. If the memory is insufficient, you can change the value to a smaller value. The value can be 16, 17, 18, 19, or 20.

A smaller value indicates less memory usage but may slightly affect the performance.

EXAGEAR_DUMP_OPTIONS

--dump-options

Enables or disables the debugging information printing function.

The configuration items actually used by the process are recorded and exported to /var/log/exagear/options.log.