TurboPFor: Bit Unpacking

This commit is contained in:
powturbo
2017-06-29 10:21:34 +02:00
parent b06d87e17b
commit fb1203b547

View File

@ -28,6 +28,10 @@
#include "vint.h"
#define PAD8(_x_) (((_x_)+7)/8)
#pragma warning( disable : 4005)
#pragma warning( disable : 4090)
#pragma warning( disable : 4068)
#pragma GCC push_options
#pragma GCC optimize ("align-functions=16")
#pragma clang diagnostic push
@ -85,7 +89,7 @@ typedef unsigned char *(*BITUNPACK_D64)(const unsigned char *__restrict in, unsi
#define BITNUNPACK(in, n, out, csize, usize) {\
unsigned char *ip = in;\
for(op = out,out+=n; op < out;) { unsigned oplen = out - op,b; if(oplen > csize) oplen = csize; __builtin_prefetch(in+512);\
for(op = out,out+=n; op < out;) { unsigned oplen = out - op,b; if(oplen > csize) oplen = csize; __builtin_prefetch(in+512,0);\
b = *ip++; ip = TEMPLATE2(bitunpacka, usize)[b](ip, oplen, op);\
op += oplen;\
} \