TurboPFor-Integer-Compression icon indicating copy to clipboard operation
TurboPFor-Integer-Compression copied to clipboard

Multiple compilation fixes for VS 2022

Open pps83 opened this issue 3 years ago • 2 comments

pps83 avatar Mar 09 '22 14:03 pps83

fixes #83

pps83 avatar Mar 09 '22 14:03 pps83

@powturbo ^^^

pps83 avatar May 07 '22 19:05 pps83

@pps83 Thanks for sending these fixes!

Unfortunately, for me, the compilation of icapp still fails on Linux:

docker build --rm -t turbopfor .
Sending build context to Docker daemon  2.048kB
Step 1/5 : FROM debian:bookworm
 ---> 408ccc77d0bf
Step 2/5 : RUN apt-get update && apt-get install -y git ca-certificates build-essential
 ---> Using cache
 ---> b478b5b4d62e
Step 3/5 : RUN git clone -b masterz https://github.com/pps83/TurboPFor
 ---> Using cache
 ---> ed59d98c595c
Step 4/5 : WORKDIR TurboPFor
 ---> Running in a6f0c099c2b2
Removing intermediate container a6f0c099c2b2
 ---> 9cafabc1cb62
Step 5/5 : RUN make
 ---> Running in b1977c75d2b9
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   icapp.c -c -o icapp.o  
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   bitpack.c -c -o bitpack.o  
cc -O3 -w -march=corei7-avx -mtune=corei7-avx  -DSSE2_ON -fstrict-aliasing -falign-loops  -c bitpack.c -o bitpack_sse.o
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   bitunpack.c -c -o bitunpack.o  
cc -O3 -w -march=corei7-avx -mtune=corei7-avx  -DSSE2_ON -fstrict-aliasing -falign-loops  -c bitunpack.c -o bitunpack_sse.o
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   vp4c.c -c -o vp4c.o  
cc -O3 -w -march=corei7-avx -mtune=corei7-avx  -DSSE2_ON -fstrict-aliasing -falign-loops  -c vp4c.c -o vp4c_sse.o
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   vp4d.c -c -o vp4d.o  
cc -O3 -w -march=corei7-avx -mtune=corei7-avx  -DSSE2_ON -fstrict-aliasing -falign-loops  -c vp4d.c -o vp4d_sse.o
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   bitutil.c -c -o bitutil.o  
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   fp.c -c -o fp.o  
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   v8.c -c -o v8.o  
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   vint.c -c -o vint.o  
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   transpose.c -c -o transpose.o  
cc -O3 -w -march=corei7-avx -mtune=corei7-avx  -DSSE2_ON -fstrict-aliasing -falign-loops  -c transpose.c -o transpose_sse.o
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   trlec.c -c -o trlec.o  
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   trled.c -c -o trled.o  
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   vsimple.c -c -o vsimple.o  
cc -O3 -march=corei7-avx -mtune=corei7-avx  -w -Wall -DNDEBUG -s -fstrict-aliasing -falign-loops   -Iext   eliasfano.c -c -o eliasfano.o  
cc -O3 -w -march=haswell -DAVX2_ON -fstrict-aliasing -falign-loops  -c bitpack.c -o bitpack_avx2.o
cc -O3 -w -march=haswell -DAVX2_ON -fstrict-aliasing -falign-loops  -c bitunpack.c -o bitunpack_avx2.o
cc -O3 -w -march=haswell -DAVX2_ON -fstrict-aliasing -falign-loops  -c vp4c.c -o vp4c_avx2.o
cc -O3 -w -march=haswell -DAVX2_ON -fstrict-aliasing -falign-loops  -c vp4d.c -o vp4d_avx2.o
cc -O3 -w -march=haswell -DAVX2_ON -fstrict-aliasing -falign-loops  -c transpose.c -o transpose_avx2.o
ar cr libic.a bitpack.o bitpack_sse.o bitunpack.o bitunpack_sse.o vp4c.o vp4c_sse.o vp4d.o vp4d_sse.o bitutil.o fp.o v8.o vint.o transpose.o transpose_sse.o trlec.o trled.o vsimple.o eliasfano.o bitpack_avx2.o bitunpack_avx2.o vp4c_avx2.o vp4d_avx2.o transpose_avx2.o
cc icapp.o libic.a -lrt -lm -o icapp
[91m/usr/bin/ld: libic.a(fp.o): in function `fpxenc32':
fp.c:(.text+0xa4b4): undefined reference to `mm_cvtsi128_si32'
/usr/bin/ld: libic.a(fp.o): in function `fpxdec32':
fp.c:(.text+0xa9a3): undefined reference to `mm_cvtsi128_si32'
[0m[91mcollect2: error: ld returned 1 exit status
[0m[91mmake: *** [makefile:125: icapp] Error 1
[0mThe command '/bin/sh -c make' returned a non-zero code: 2

In case you’re curious how I’m compiling, this is the Dockerfile I’m using:

FROM debian:bookworm

RUN apt-get update && apt-get install -y git ca-certificates build-essential

RUN git clone -b masterz https://github.com/pps83/TurboPFor
WORKDIR TurboPFor

RUN make

stapelberg avatar Feb 01 '23 20:02 stapelberg