Skip to content

Commit

Permalink
v3.8.0
Browse files Browse the repository at this point in the history
  • Loading branch information
JayDDee committed Jan 24, 2018
1 parent a90d75b commit ad2275f
Show file tree
Hide file tree
Showing 121 changed files with 4,670 additions and 475 deletions.
13 changes: 11 additions & 2 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ cpuminer_SOURCES = \
api.c \
sysinfos.c \
algo-gate-api.c\
crypto/blake2s.c \
crypto/oaes_lib.c \
crypto/c_keccak.c \
crypto/c_groestl.c \
Expand All @@ -45,6 +44,7 @@ cpuminer_SOURCES = \
algo/blake/blake-4way.c \
algo/blake/sph_blake2b.c \
algo/blake/blake2b.c \
algo/blake/sph-blake2s.c \
algo/blake/blake2s.c \
algo/blake/blakecoin-gate.c \
algo/blake/mod_blakecoin.c \
Expand Down Expand Up @@ -75,7 +75,9 @@ cpuminer_SOURCES = \
algo/groestl/aes_ni/hash-groestl256.c \
algo/fugue/sph_fugue.c \
algo/hamsi/sph_hamsi.c \
algo/haval/haval.c\
algo/hamsi/hamsi-hash-4way.c \
algo/haval/haval.c \
algo/haval/haval-hash-4way.c \
algo/heavy/sph_hefty1.c \
algo/heavy/heavy.c \
algo/heavy/bastion.c \
Expand Down Expand Up @@ -122,13 +124,17 @@ cpuminer_SOURCES = \
algo/quark/quark-gate.c \
algo/quark/quark.c \
algo/quark/quark-4way.c \
algo/quark/anime-gate.c \
algo/quark/anime.c \
algo/quark/anime-4way.c \
algo/qubit/qubit.c \
algo/qubit/deep.c \
algo/ripemd/sph_ripemd.c \
algo/scrypt.c \
algo/scryptjane/scrypt-jane.c \
algo/sha/sph_sha2.c \
algo/sha/sph_sha2big.c \
algo/sha/sha2-hash-4way.c \
algo/sha/sha2.c \
algo/sha/sha256t.c \
algo/shabal/sph_shabal.c \
Expand Down Expand Up @@ -210,6 +216,9 @@ cpuminer_SOURCES = \
algo/x17/xevan-gate.c \
algo/x17/xevan.c \
algo/x17/xevan-4way.c \
algo/x17/x16r-gate.c \
algo/x17/x16r.c \
algo/x17/x16r-4way.c \
algo/x17/hmq1725.c \
algo/yescrypt/yescrypt.c \
algo/yescrypt/sha256_Y.c \
Expand Down
16 changes: 3 additions & 13 deletions README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,19 +19,9 @@ Users are recommended to use an unoptimized miner such as cpuminer-multi.

Exe name Compile flags Arch name

cpuminer-sse2.exe "-march=core2" Core2
cpuminer-sse42.exe "-march=corei7" Nehalem
cpuminer-sse2.exe "-march=core2" Core2, Nehalem
cpuminer-aes-sse42.exe "-maes -msse4.2" Westmere
cpuminer-avx.exe "-march=corei7-avx" Sandybridge, Ivybridge
cpuminer-aes-avx.exe "-march=corei7-avx" Sandybridge, Ivybridge
cpuminer-avx2.exe "-march=core-avx2" Haswell...
cpuminer-avx-sha "-march=corei7-avx -msha" Ryzen...
cpuminer-4way.exe "-march=core-avx2 -DFOUR_WAY" same as avx2
cpuminer-4way-sha.exe "-march=core-avx2 -msha -DFOUR_WAY" same as avx2-sha

4way requires a CPU with AES and AVX2. It is still under development and
only a few algos are supported. See change log in RELEASE_NOTES in source
package for supported algos.

Ryzen CPus perform better with AVX than AVX2 therefore an avx-sha build
is provided. Four way still uses AVX2.
cpuminer-avx2-sha.exe "-march=core-avx2 -msha" Ryzen

20 changes: 11 additions & 9 deletions RELEASE_NOTES
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,6 @@ SPH may give slightly better performance on algos that use sha256 when using
openssl 1.0.1 or older. Openssl 1.0.2 adds AVX2 and 1.1 adds SHA and perform
better than SPH.

-DFOUR_WAY

4 way will give much better performance on supported algos with CPUs
that have AVX2 and should only be used on CPUs with AVX2. 4 way algo
support will be added incrementally, see change log below for supported algos.

Start mining.

./cpuminer -a algo -o url -u username -p password
Expand Down Expand Up @@ -149,9 +143,9 @@ cpuminer.exe -a algo -o url -u user -p password

The following tips may be useful for older AMD CPUs.

AMD CPUs older than Piledriver, including Athlon x2 and Phenom II x4, are not
supported by cpuminer-opt due to an incompatible implementation of SSE2 on
these CPUs. Some algos may crash the miner with an invalid instruction.
AMD CPUs older than Steamroller, including Athlon x2 and Phenom II x4, are
not supported by cpuminer-opt due to an incompatible implementation of SSE2
on these CPUs. Some algos may crash the miner with an invalid instruction.
Users are recommended to use an unoptimized miner such as cpuminer-multi.

Some users with AMD CPUs without AES_NI have reported problems compiling
Expand All @@ -165,6 +159,14 @@ Support for even older x86_64 without AES_NI or SSE2 is not availble.
Change Log
----------

v3.7.11

4way no longer a seperate feature, included in AVX2.
Added x16r algo for Ravencoin, anime algo for Animecoin.
More 4way optimizations for X13 and up.
Tweaked CPU affinity to better support more than 64 CPUs.
Fixed compile problem on some old AMD CPUs.

v3.7.10

4way optimizations for lyra2rev2, lyra2h, quark, timetravel8, timetravel10
Expand Down
4 changes: 3 additions & 1 deletion algo-gate-api.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include <memory.h>
#include <unistd.h>
#include <openssl/sha.h>
#include "miner.h"
//#include "miner.h"
#include "algo-gate-api.h"

// Define null and standard functions.
Expand Down Expand Up @@ -155,6 +155,7 @@ bool register_algo_gate( int algo, algo_gate_t *gate )

switch (algo)
{
case ALGO_ANIME: register_anime_algo ( gate ); break;
case ALGO_ARGON2: register_argon2_algo ( gate ); break;
case ALGO_AXIOM: register_axiom_algo ( gate ); break;
case ALGO_BASTION: register_bastion_algo ( gate ); break;
Expand Down Expand Up @@ -216,6 +217,7 @@ bool register_algo_gate( int algo, algo_gate_t *gate )
case ALGO_X13SM3: register_x13sm3_algo ( gate ); break;
case ALGO_X14: register_x14_algo ( gate ); break;
case ALGO_X15: register_x15_algo ( gate ); break;
case ALGO_X16R: register_x16r_algo ( gate ); break;
case ALGO_X17: register_x17_algo ( gate ); break;
case ALGO_XEVAN: register_xevan_algo ( gate ); break;
case ALGO_YESCRYPT: register_yescrypt_algo ( gate ); break;
Expand Down
6 changes: 3 additions & 3 deletions algo-gate-api.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#include <stdlib.h>
#include <stdbool.h>
#include <stdint.h>

#include "miner.h"

/////////////////////////////
Expand Down Expand Up @@ -91,7 +90,7 @@ typedef uint32_t set_t;
#define AVX_OPT 4
#define AVX2_OPT 8
#define SHA_OPT 0x10
#define FOUR_WAY_OPT 0x20
//#define FOUR_WAY_OPT 0x20

// return set containing all elements from sets a & b
inline set_t set_union ( set_t a, set_t b ) { return a | b; }
Expand Down Expand Up @@ -213,7 +212,8 @@ int64_t get_max64_0x3fffffLL();
int64_t get_max64_0x1ffff();
int64_t get_max64_0xffffLL();

void std_set_target ( struct work *work, double job_diff );
void std_set_target( struct work *work, double job_diff );
void alt_set_target( struct work* work, double job_diff );
void scrypt_set_target( struct work *work, double job_diff );

bool std_le_work_decode( const json_t *val, struct work *work );
Expand Down
2 changes: 1 addition & 1 deletion algo/blake/blake-4way.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#include "blake-gate.h"

#if defined (__AVX__)
#if defined (BLAKE_4WAY)

#include "blake-hash-4way.h"
#include <string.h>
Expand Down
2 changes: 1 addition & 1 deletion algo/blake/blake-gate.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ int64_t blake_get_max64 ()

bool register_blake_algo( algo_gate_t* gate )
{
gate->optimizations = AVX2_OPT;
gate->get_max64 = (void*)&blake_get_max64;
//#if defined (__AVX2__) && defined (FOUR_WAY)
// gate->optimizations = SSE2_OPT | AVX_OPT | AVX2_OPT;
// gate->scanhash = (void*)&scanhash_blake_8way;
// gate->hash = (void*)&blakehash_8way;
#if defined(BLAKE_4WAY)
four_way_not_tested();
gate->optimizations = FOUR_WAY_OPT;
gate->scanhash = (void*)&scanhash_blake_4way;
gate->hash = (void*)&blakehash_4way;
#else
Expand Down
2 changes: 1 addition & 1 deletion algo/blake/blake-gate.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#include "algo-gate-api.h"
#include <stdint.h>

#if defined(FOUR_WAY) && defined(__AVX__)
#if defined(__AVX2__)
#define BLAKE_4WAY
#endif

Expand Down
Loading

0 comments on commit ad2275f

Please sign in to comment.