Fixed ARM code

This commit is contained in:
SChernykh 2019-02-10 16:04:24 +01:00
parent 65dab8371b
commit 36ce144d35
2 changed files with 16 additions and 13 deletions

View file

@ -29,7 +29,7 @@
#include <stddef.h>
#include <stdint.h>
#ifdef _MSC_VER
#if defined _MSC_VER || defined XMRIG_ARM
#define ABI_ATTRIBUTE
#else
#define ABI_ATTRIBUTE __attribute__((ms_abi))

View file

@ -515,10 +515,11 @@ inline void cryptonight_single_hash(const uint8_t *__restrict__ input, size_t si
ch = ((uint64_t*) &l0[idx0 & MASK])[1];
if (BASE == xmrig::VARIANT_2) {
if (VARIANT == xmrig::VARIANT_WOW) {
VARIANT4_RANDOM_MATH(0, al0, ah0, cl, bx0, bx1);
} else {
VARIANT2_INTEGER_MATH(0, cl, cx);
}
else if (VARIANT == xmrig::VARIANT_WOW) {
VARIANT4_RANDOM_MATH(0, al0, ah0, cl, bx0, bx1);
}
lo = __umul128(idx0, cl, &hi);
@ -685,10 +686,11 @@ inline void cryptonight_double_hash(const uint8_t *__restrict__ input, size_t si
ch = ((uint64_t*) &l0[idx0 & MASK])[1];
if (BASE == xmrig::VARIANT_2) {
if (VARIANT == xmrig::VARIANT_WOW) {
VARIANT4_RANDOM_MATH(0, al0, ah0, cl, bx00, bx01);
} else {
VARIANT2_INTEGER_MATH(0, cl, cx0);
}
else if (VARIANT == xmrig::VARIANT_WOW) {
VARIANT4_RANDOM_MATH(0, al0, ah0, cl, bx00, bx01);
}
lo = __umul128(idx0, cl, &hi);
@ -734,10 +736,11 @@ inline void cryptonight_double_hash(const uint8_t *__restrict__ input, size_t si
ch = ((uint64_t*) &l1[idx1 & MASK])[1];
if (BASE == xmrig::VARIANT_2) {
if (VARIANT == xmrig::VARIANT_WOW) {
VARIANT4_RANDOM_MATH(1, al1, ah1, cl, bx10, bx11);
} else {
VARIANT2_INTEGER_MATH(1, cl, cx1);
}
else if (VARIANT == xmrig::VARIANT_WOW) {
VARIANT4_RANDOM_MATH(1, al1, ah1, cl, bx10, bx11);
}
lo = __umul128(idx1, cl, &hi);