cpuminer-opt 3.6.1 is released and available for download.
It fixes a data alignment issue in Lyra2Rev2 and also adds support for HW accelerated SHA
encryption and decryption available on Ryzen CPUs. No mainstream intel CPUs with SHA
are exepected until Cannonlake.
SHA256 is used by the following algos and should benefit from HW acceleration:
sha256t, lbry, skein, myr-groestl, m7m.
In order to make use of SHA several requirements must be met. It may require
installation of packages newer than available in the distribution as SHA
support is still very new.
Windows binaries are not avaialable and I have not yet investigated compiling
with SHA support on Windows.
Requirements:
Ryzen CPU
Recent Linux distribution
Compiler version with support for sha
Openssl development package with support for sha
Cpuminer-opt source code with support for sha
This is more of a what-to than a how-to, users should already know how.
1. Confirm CPU has SHA support availble and enabled
2. Confirm compiler has support for SHA (gcc 5+).
3. Confirm openssl has support for SHA.
https://github.com/openssl/openssl/commit/619b94667cc7a097f6d1e2123c4f4c2c85afb8f74. Configure with arch that includes sha or manually add "-msha" to CFLAGS.
5. Compile.
Recommended test plan:
SHA support in cpuminer-opt is untested therefore problems are likely. Please include all relevant
information, including compiler and openssl versions, when reporting problems.
In addition to SHA, Ryzen is the first AMD CPU to include AVX2. Before attempting to use SHA it would
be useful to determine a baseline configuration for this architecture. Does "-march=core-avx2" provide
an optimum build for Ryzen?
Use the best build as a baseline for comparison with SHA acceleration.
Choose one or more algos that use sha256 (listed above) and obtain baseline performance data.
Rebuild with SHA support. Does the compiler recognize "-march=ryzen" and does it include sha?
Otherwise add "-msha" to the baseline configuration.
Compare performance and report.