Open leahneukirchen opened 2 years ago
List of tests segfaulting:
g022.ijs
g110.ijs
g122.ijs
g221.ijs
g320ip.ijs
g3x.ijs
g422.ijs
g422os.ijs
g422sort.ijs
g432.ijs
gicap2.ijs
gqco.ijs
gspi.ijs
Reproducer:
t1 =. 1&<.&.(0.05&+)&.> <@((?@$)&0)"1 (3+i.3) ,"0/ 1+i.50
t2 =. 1&<.&.(0.05&+)&.> <@((?@$)&0)"1 $@> t1
f =. 1 : 0
:
({."1&.> x) ((u f.)!.0"+"+ -: (u f.)!.0)&> y
)
t1 >: f t2
Crashing functions for the first next few:
g110: ltDD
g122: i0eqDD0 __emu_mm256_cmp_pd
g221: jtsortdq sortdq1
Tests pass for the AVX1 version. The AVX2 version doesn't seem to start, even though my CPU should have AVX2? (but not AVX-512).
I suspect it ran into bus error in the function/macro __emu_mm256_cmp_pd probably misaligned access to sse registers. From your cpuinfo, there seems no avx2 flag so that avx2 version can't run.
You can try compile with -O0 or using clang. Only clang is officially supported for J source.
I tried on centos with gcc 8, it gave warnings. It is on your own to use gcc.
../../../../jsrc/avxintrin-emu.h: In function 'emu_mm256_maskload_pd': ../../../../jsrc/avxintrin-emu.h:1348:22: note: The ABI for passing parameters with 32-byte alignment has changed in GCC 4.6 emu_maskload_impl( emu_mm256_maskload_pd, emum256d, emum256i, double, emu_int64_t );
My cpu has avx
and avx2
in /proc/cpuinfo flags, isn't that enough?
I'll check clang.
With clang 12.0.1, non-AVX test succeeds, but both AVX and AVX2 don't start now. :(
I believe the problem is your computer, try run on another computer or build again with debug.
For the record, j901f works fine. I don't think it's my computer, I use it to build all kinds of things and never had a problem...
The AVX versions also don't work on a Intel(R) Core(TM) i7-8550U CPU, which has AVX, AVX2 but no AVX-512.
I'm pretty sure avx and avx2 binaries are good. You can download binaries from our website. They are built on github.
what happens if you add -falign-functions=4 to the cflags?
I don't think your suggestion would work. The issue is about abi.
On Void Linux x86_64 glibc (gcc (GCC) 10.2.1 20201203), updating J to 903 release b fails the test suite:
I'm not sure how to dump the offending line.
CPU is
There is also an error during build with
-Werror
:Which I had overriden to be ignored.