From 54b8fd7362ae8f90173c930e304a64653480d8f4 Mon Sep 17 00:00:00 2001 From: Jay D Dee Date: Mon, 5 Feb 2018 22:10:18 -0500 Subject: [PATCH] v3.8.0.1 --- RELEASE_NOTES | 2 +- algo/x17/x16r-4way.c | 55 +++++++++++++++++++------------------------- configure | 20 ++++++++-------- configure.ac | 2 +- 4 files changed, 36 insertions(+), 43 deletions(-) diff --git a/RELEASE_NOTES b/RELEASE_NOTES index b6742ef9..6c588ab6 100644 --- a/RELEASE_NOTES +++ b/RELEASE_NOTES @@ -159,7 +159,7 @@ Support for even older x86_64 without AES_NI or SSE2 is not availble. Change Log ---------- -v3.7.11 +v3.8.0 4way no longer a seperate feature, included in AVX2. Added x16r algo for Ravencoin, anime algo for Animecoin. diff --git a/algo/x17/x16r-4way.c b/algo/x17/x16r-4way.c index 14c5ba52..6b967af0 100644 --- a/algo/x17/x16r-4way.c +++ b/algo/x17/x16r-4way.c @@ -63,29 +63,26 @@ void init_x16r_4way_ctx() void x16r_4way_hash( void* output, const void* input ) { - uint32_t hash0[16] __attribute__ ((aligned (64))); - uint32_t hash1[16] __attribute__ ((aligned (64))); - uint32_t hash2[16] __attribute__ ((aligned (64))); - uint32_t hash3[16] __attribute__ ((aligned (64))); - uint32_t vhash[16*4] __attribute__ ((aligned (64))); - uint32_t inp0[24] __attribute__ ((aligned (64))); - uint32_t inp1[24] __attribute__ ((aligned (64))); - uint32_t inp2[24] __attribute__ ((aligned (64))); - uint32_t inp3[24] __attribute__ ((aligned (64))); + uint32_t hash0[24] __attribute__ ((aligned (64))); + uint32_t hash1[24] __attribute__ ((aligned (64))); + uint32_t hash2[24] __attribute__ ((aligned (64))); + uint32_t hash3[24] __attribute__ ((aligned (64))); + uint32_t vhash[24*4] __attribute__ ((aligned (64))); x16r_4way_ctx_holder ctx; - void *in0 = (void*) inp0; - void *in1 = (void*) inp1; - void *in2 = (void*) inp2; - void *in3 = (void*) inp3; + void *in0 = (void*) hash0; + void *in1 = (void*) hash1; + void *in2 = (void*) hash2; + void *in3 = (void*) hash3; + int size = 80; - mm256_deinterleave_4x64( inp0, inp1, inp2, inp3, input, 640 ); + mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, input, 640 ); if ( s_ntime == UINT32_MAX ) { - const uint8_t* tmp = (uint8_t*) inp0; + const uint8_t* tmp = (uint8_t*) in0; x16r_getAlgoString( &tmp[4], hashOrder ); } @@ -114,7 +111,7 @@ void x16r_4way_hash( void* output, const void* input ) blake512_4way( &ctx.blake, vhash, size ); } blake512_4way_close( &ctx.blake, vhash ); - mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, 512 ); + mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, size<<3 ); break; case BMW: bmw512_4way_init( &ctx.bmw ); @@ -126,7 +123,7 @@ void x16r_4way_hash( void* output, const void* input ) bmw512_4way( &ctx.bmw, vhash, size ); } bmw512_4way_close( &ctx.bmw, vhash ); - mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, 512 ); + mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, size<<3 ); break; case GROESTL: init_groestl( &ctx.groestl, 64 ); @@ -152,7 +149,7 @@ void x16r_4way_hash( void* output, const void* input ) skein512_4way( &ctx.skein, vhash, size ); } skein512_4way_close( &ctx.skein, vhash ); - mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, 512 ); + mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, size<<3 ); break; case JH: jh512_4way_init( &ctx.jh ); @@ -164,7 +161,7 @@ void x16r_4way_hash( void* output, const void* input ) jh512_4way( &ctx.jh, vhash, size ); } jh512_4way_close( &ctx.jh, vhash ); - mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, 512 ); + mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, size<<3 ); break; case KECCAK: keccak512_4way_init( &ctx.keccak ); @@ -176,7 +173,7 @@ void x16r_4way_hash( void* output, const void* input ) keccak512_4way( &ctx.keccak, vhash, size ); } keccak512_4way_close( &ctx.keccak, vhash ); - mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, 512 ); + mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, size<<3 ); break; case LUFFA: init_luffa( &ctx.luffa, 512 ); @@ -253,7 +250,7 @@ void x16r_4way_hash( void* output, const void* input ) hamsi512_4way_init( &ctx.hamsi ); hamsi512_4way( &ctx.hamsi, vhash, size ); hamsi512_4way_close( &ctx.hamsi, vhash ); - mm_deinterleave_4x32( hash0, hash1, hash2, hash3, vhash, 512 ); + mm_deinterleave_4x32( hash0, hash1, hash2, hash3, vhash, size<<3 ); break; case FUGUE: sph_fugue512_init( &ctx.fugue ); @@ -274,7 +271,7 @@ void x16r_4way_hash( void* output, const void* input ) shabal512_4way_init( &ctx.shabal ); shabal512_4way( &ctx.shabal, vhash, size ); shabal512_4way_close( &ctx.shabal, vhash ); - mm_deinterleave_4x32( hash0, hash1, hash2, hash3, vhash, 512 ); + mm_deinterleave_4x32( hash0, hash1, hash2, hash3, vhash, size<<3 ); break; case WHIRLPOOL: sph_whirlpool_init( &ctx.whirlpool ); @@ -295,13 +292,9 @@ void x16r_4way_hash( void* output, const void* input ) sha512_4way_init( &ctx.sha512 ); sha512_4way( &ctx.sha512, vhash, size ); sha512_4way_close( &ctx.sha512, vhash ); - mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, 512 ); + mm256_deinterleave_4x64( hash0, hash1, hash2, hash3, vhash, size<<3 ); break; } - in0 = (void*) hash0; - in1 = (void*) hash1; - in2 = (void*) hash2; - in3 = (void*) hash3; size = 64; } memcpy( output, hash0, 32 ); @@ -358,28 +351,28 @@ int scanhash_x16r_4way( int thr_id, struct work *work, uint32_t max_nonce, x16r_4way_hash( hash, vdata ); pdata[19] = n; - if ( hash[7] <= Htarg && fulltest( hash, ptarget ) ) + if ( ( hash[7] <= Htarg ) && fulltest( hash, ptarget ) ) { found[0] = true; num_found++; nonces[0] = n; work_set_target_ratio( work, hash ); } - if ( (hash+8)[7] <= Htarg && fulltest( hash, ptarget ) ) + if ( ( (hash+8)[7] <= Htarg ) && fulltest( hash+8, ptarget ) ) { found[1] = true; num_found++; nonces[1] = n+1; work_set_target_ratio( work, hash+8 ); } - if ( (hash+16)[7] <= Htarg && fulltest( hash, ptarget ) ) + if ( ( (hash+16)[7] <= Htarg ) && fulltest( hash+16, ptarget ) ) { found[2] = true; num_found++; nonces[2] = n+2; work_set_target_ratio( work, hash+16 ); } - if ( (hash+24)[7] <= Htarg && fulltest( hash, ptarget ) ) + if ( ( (hash+24)[7] <= Htarg ) && fulltest( hash+24, ptarget ) ) { found[3] = true; num_found++; diff --git a/configure b/configure index c98f3133..95ac9745 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for cpuminer-opt 3.8.0. +# Generated by GNU Autoconf 2.69 for cpuminer-opt 3.8.0.1. # # # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. @@ -577,8 +577,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='cpuminer-opt' PACKAGE_TARNAME='cpuminer-opt' -PACKAGE_VERSION='3.8.0' -PACKAGE_STRING='cpuminer-opt 3.8.0' +PACKAGE_VERSION='3.8.0.1' +PACKAGE_STRING='cpuminer-opt 3.8.0.1' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -1321,7 +1321,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures cpuminer-opt 3.8.0 to adapt to many kinds of systems. +\`configure' configures cpuminer-opt 3.8.0.1 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1392,7 +1392,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of cpuminer-opt 3.8.0:";; + short | recursive ) echo "Configuration of cpuminer-opt 3.8.0.1:";; esac cat <<\_ACEOF @@ -1497,7 +1497,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -cpuminer-opt configure 3.8.0 +cpuminer-opt configure 3.8.0.1 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -2000,7 +2000,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by cpuminer-opt $as_me 3.8.0, which was +It was created by cpuminer-opt $as_me 3.8.0.1, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -2981,7 +2981,7 @@ fi # Define the identity of the package. PACKAGE='cpuminer-opt' - VERSION='3.8.0' + VERSION='3.8.0.1' cat >>confdefs.h <<_ACEOF @@ -6677,7 +6677,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by cpuminer-opt $as_me 3.8.0, which was +This file was extended by cpuminer-opt $as_me 3.8.0.1, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -6743,7 +6743,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -cpuminer-opt config.status 3.8.0 +cpuminer-opt config.status 3.8.0.1 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" diff --git a/configure.ac b/configure.ac index 686830aa..b8981e6b 100644 --- a/configure.ac +++ b/configure.ac @@ -1,4 +1,4 @@ -AC_INIT([cpuminer-opt], [3.8.0]) +AC_INIT([cpuminer-opt], [3.8.0.1]) AC_PREREQ([2.59c]) AC_CANONICAL_SYSTEM