diff --unified --recursive --text src.old/libs/powzix/kraken.cpp src.new/libs/powzix/kraken.cpp
--- src.old/libs/powzix/kraken.cpp 2021-02-12 18:31:26.000000000 -0500
+++ src.new/libs/powzix/kraken.cpp 2021-06-28 11:36:23.583579008 -0400
@@ -19,13 +19,6 @@
#include "stdafx.h"
- static unsigned int _rotl( unsigned int value, int shift )
- {
- int max_bits = sizeof(value)<<3;
- if ( shift > max_bits )
- shift = shift % max_bits;
- return (value << shift) | (value >> (max_bits-shift));
- }
// Header in front of each 256k block
typedef struct KrakenHeader {
@@ -348,14 +341,12 @@
uint32 w, m, n, rv;
if (v < 0xF0) {
n = (v >> 4) + 4;
- w = _rotl(bits->bits | 1, n);
bits->bitpos += n;
m = (2 << n) - 1;
bits->bits = w & ~m;
rv = ((w & m) << 4) + (v & 0xF) - 248;
} else {
n = v - 0xF0 + 4;
- w = _rotl(bits->bits | 1, n);
bits->bitpos += n;
m = (2 << n) - 1;
bits->bits = w & ~m;
@@ -375,14 +366,12 @@
uint32 w, m, n, rv;
if (v < 0xF0) {
n = (v >> 4) + 4;
- w = _rotl(bits->bits | 1, n);
bits->bitpos += n;
m = (2 << n) - 1;
bits->bits = w & ~m;
rv = ((w & m) << 4) + (v & 0xF) - 248;
} else {
n = v - 0xF0 + 4;
- w = _rotl(bits->bits | 1, n);
bits->bitpos += n;
m = (2 << n) - 1;
bits->bits = w & ~m;
@@ -1458,10 +1447,7 @@
int numbits_f = interval_lenlog2[i + 0];
int numbits_b = interval_lenlog2[i + 1];
- bits_f = _rotl(bits_f | 1, numbits_f);
bitpos_f += numbits_f - 8 * ((bitpos_f + 7) >> 3);
-
- bits_b = _rotl(bits_b | 1, numbits_b);
bitpos_b += numbits_b - 8 * ((bitpos_b + 7) >> 3);
int value_f = bits_f & bitmasks[numbits_f];
@@ -1478,7 +1464,6 @@
if (i < num_lens) {
bits_f |= _byteswap_ulong(*(uint32*)f) >> (24 - bitpos_f);
int numbits_f = interval_lenlog2[i];
- bits_f = _rotl(bits_f | 1, numbits_f);
int value_f = bits_f & bitmasks[numbits_f];
decoded_intervals[i + 0] = value_f;
}
diff --unified --recursive --text src.old/Makefile src.new/Makefile
--- src.old/Makefile 2021-04-03 19:28:16.000000000 -0400
+++ src.new/Makefile 2021-06-27 22:58:02.148647514 -0400
@@ -19,10 +19,8 @@
USE_OPENSSL = 1
else
CLIBS += -static-libgcc
-ifeq ($(filter-out %86, $(shell uname -m)),)
EXTRA_TARGETS = libs/amiga/amiga.s libs/powzix/*.cpp
CFLAGS += -msse2
-endif
USE_OPENSSL = 1
endif