Hardware Compression Acceleration
Hardware Compression Acceleration (HCA) is an optional function provided by PowerNukkitX, which can accelerate data compression by using hardware SIMD on modern CPUs.
Why?
PowerNukkitX is suitable for large servers. Many servers carry dozens or even hundreds of player at the same time, which means that each player will generate a large amount of data. Due to the requirements of the bedrock version, this data needs to be compressed before it is sent to a player.
At the same time, when a player runs around a map, a large number of chunks generated also need to be compressed and decompressed frequently.
The data required to be compressed or decompressed consumes a lot of CPU resources. Using HCA can greatly improve the performance.
What CPU can enable this?
If your CPU is able to enable hardware accelerated compression, you will be prompted on startup.
When your CPU supports one or more of the following instruction sets, HCA can be enabled. The more instruction sets supported, the more advanced and the greater the performance improvement will be:
Instruction set | explain |
---|---|
AVX512 | Intel/AMD |
AVX2 | Intel/AMD |
AVX | Intel/AMD |
SSE4.2 | Intel/AMD |
SSE4.1 | Intel/AMD |
SSSE3 | Intel/AMD |
SSE3 | Intel/AMD |
SSE2 | Intel/AMD |
SSE | Intel/AMD |
SVE | ARMv8.2+ |
NEON | ARMv7+ |
How to enable it?
Open the configuration file pnx.yml.
Locate the network
tab.
Set zlibProvider
to 3
.
network:
zlibProvider: 3