zfs/man/man8
Attila Fülöp 76354f945e ICP: Improve AES-GCM performance
Currently SIMD accelerated AES-GCM performance is limited by two
factors:

a. The need to disable preemption and interrupts and save the FPU
state before using it and to do the reverse when done. Due to the
way the code is organized (see (b) below) we have to pay this price
twice for each 16 byte GCM block processed.

b. Most processing is done in C, operating on single GCM blocks.
The use of SIMD instructions is limited to the AES encryption of the
counter block (AES-NI) and the Galois multiplication (PCLMULQDQ).
This leads to the FPU not being fully utilized for crypto
operations.

To solve (a) we do crypto processing in larger chunks while owning
the FPU. An `icp_gcm_avx_chunk_size` module parameter was introduced
to make this chunk size tweakable. It defaults to 32 KiB. This step
alone roughly doubles performance. (b) is tackled by porting and
using the highly optimized openssl AES-GCM assembler routines, which
do all the processing (CTR, AES, GMULT) in a single routine. Both
steps together result in up to 32x reduction of the time spend in
the en/decryption routines, leading up to approximately 12x
throughput increase for large (128 KiB) blocks.

Lastly, this commit changes the default encryption algorithm from
AES-CCM to AES-GCM when setting the `encryption=on` property.

Reviewed-By: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-By: Jason King <jason.king@joyent.com>
Reviewed-By: Tom Caputi <tcaputi@datto.com>
Reviewed-By: Richard Laager <rlaager@wiktel.com>
Signed-off-by: Attila Fülöp <attila@fueloep.org>
Closes #9749
2020-05-12 10:53:32 -07:00
..
.gitignore Ignore *.o.ur-safe build artifacts 2018-05-13 18:59:02 -07:00
Makefile.am Systemd mount generator: Generate noauto units; add control properties 2020-05-12 10:53:32 -07:00
fsck.zfs.8 Fix NAME section of manpages zhack and fsck.zfs. 2014-03-10 09:19:17 -07:00
mount.zfs.8 zfs.8 & mount.zfs.8: fix a few typos 2016-05-16 12:26:31 -07:00
vdev_id.8 vdev_id support for device link aliases 2012-12-03 14:04:47 -08:00
zdb.8 zio_decompress_data always ASSERTs successful decompression 2020-01-22 13:49:05 -08:00
zed.8.in Tunable directory for zfs runtime scripts 2018-06-07 09:59:59 -07:00
zfs-mount-generator.8.in Systemd mount generator: Generate noauto units; add control properties 2020-05-12 10:53:32 -07:00
zfs-program.8 Correct man page dates 2019-05-08 10:59:32 -07:00
zfs.8 ICP: Improve AES-GCM performance 2020-05-12 10:53:32 -07:00
zfsprops.8 ICP: Improve AES-GCM performance 2020-05-12 10:53:32 -07:00
zgenhostid.8 Correct man page dates 2019-05-08 10:59:32 -07:00
zinject.8 Multiple DVA Scrubbing Fix 2019-03-15 14:14:31 -07:00
zpool.8 Implement ZPOOL_IMPORT_UDEV_TIMEOUT_MS 2020-01-22 13:49:03 -08:00
zstreamdump.8 Eliminate useless double-bolding in man pages 2019-04-24 17:04:35 -07:00