Implementation notes: amd64, h8atom, crypto_scalarmult/kummer

Computer: h8atom
Microarchitecture: amd64; Bonnell (30661)
Architecture: amd64
CPU ID: GenuineIntel-00030661-bfebfbff
SUPERCOP version: 20240107
Operation: crypto_scalarmult
Primitive: kummer
TimeObject sizeTest sizeImplementationCompilerBenchmark dateSUPERCOP version
698656715526 0 036572 824 1568ref5uclang_-march=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2023121620231212
705162513623 0 033468 824 1568ref5uclang_-march=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2023121620231212
706147415428 0 036484 824 1568ref5clang_-march=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2023121620231212
707637013356 0 033188 824 1568ref5clang_-march=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2023121620231212
71454464512 0 022486 816 1568ref5clang_-march=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2023121620231212
71988074952 0 024886 784 1632ref5ugcc_-march=native_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2023121620231212
72089434773 0 022734 816 1568ref5uclang_-march=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2023121620231212
72190514645 0 024558 784 1632ref5gcc_-march=native_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2023121620231212
745745013943 0 034756 824 1568ref5clang_-mcpu=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2023121620231212
74948794734 0 022614 776 1600ref5ugcc_-march=native_-mtune=native_-Os_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2023121620231212
749984214185 0 035036 824 1568ref5uclang_-mcpu=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2023121620231212
760357513602 0 032308 824 1568ref5clang_-march=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2023121620231212
76483124446 0 022294 776 1600ref5gcc_-march=native_-mtune=native_-Os_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2023121620231212
76954016970 0 028142 784 1632ref5gcc_-march=native_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2023121620231212
778488213901 0 032604 824 1568ref5uclang_-march=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2023121620231212
80155817346 0 028558 784 1632ref5ugcc_-march=native_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2023121620231212
80178564761 0 023854 784 1632ref5gcc_-march=native_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2023121620231212
80460035078 0 024182 784 1632ref5ugcc_-march=native_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2023121620231212

Test failure

Implementation: avx
Security model: constbranchindex
Compiler: clang -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
error 111

Number of similar (compiler,implementation) pairs: 17, namely:
CompilerImplementations
clang -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx
clang -march=native -O3 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx
clang -march=native -O -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx
clang -march=native -Os -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx
clang -mcpu=native -O3 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx
gcc -march=native -mtune=native -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE avx
gcc -march=native -mtune=native -O -fomit-frame-pointer -fwrapv -fPIC -fPIE avx
gcc -march=native -mtune=native -Os -fomit-frame-pointer -fwrapv -fPIC -fPIE avx
clang -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2
clang -march=native -O3 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2
clang -march=native -O -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2
clang -march=native -Os -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2
clang -mcpu=native -O3 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2
gcc -march=native -mtune=native -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE avx2
gcc -march=native -mtune=native -O3 -fomit-frame-pointer -fwrapv -fPIC -fPIE avx2
gcc -march=native -mtune=native -O -fomit-frame-pointer -fwrapv -fPIC -fPIE avx2
gcc -march=native -mtune=native -Os -fomit-frame-pointer -fwrapv -fPIC -fPIE avx2

Compiler output

Implementation: avx
Security model: constbranchindex
Compiler: gcc -march=native -mtune=native -O3 -fomit-frame-pointer -fwrapv -fPIC -fPIE
try.c: /usr/bin/ld: error in /home/supercop/benchmarking/supercop-20231212/supercop-data/h8atom/amd64/lib/libsupercop.a(crypto_rng_chacha20_ref_constbranchindex-rng.o)(.eh_frame); no .eh_frame_hdr table will be created
try.c: /usr/bin/ld: error in /home/supercop/benchmarking/supercop-20231212/supercop-data/h8atom/amd64/lib/libsupercop.a(crypto_stream_chacha20_moon_sse2_64_constbranchindex-crypto_stream.o)(.eh_frame); no .eh_frame_hdr table will be created
try.c: /home/supercop/benchmarking/supercop-20231212/supercop-data/h8atom/amd64/lib/libsupercop.a(crypto_rng_chacha20_ref_constbranchindex-rng.o):(.text+0x...): relocation truncated to fit: R_X86_64_PC32 against `*UND*'
try.c: /home/supercop/benchmarking/supercop-20231212/supercop-data/h8atom/amd64/lib/libsupercop.a(crypto_rng_chacha20_ref_constbranchindex-rng.o):(.eh_frame+0x20): relocation truncated to fit: R_X86_64_PC32 against `*UND*'
try.c: /usr/bin/ld: /home/supercop/benchmarking/supercop-20231212/supercop-data/h8atom/amd64/lib/libsupercop.a(crypto_stream_chacha20_moon_sse2_64_constbranchindex-crypto_stream.o): invalid string offset 19932316 >= 268 for section `.strtab'
try.c: /usr/bin/ld: /home/supercop/benchmarking/supercop-20231212/supercop-data/h8atom/amd64/lib/libsupercop.a(crypto_stream_chacha20_moon_sse2_64_constbranchindex-crypto_stream.o): invalid string offset 19932316 >= 268 for section `.strtab'
try.c: /usr/bin/ld: /home/supercop/benchmarking/supercop-20231212/supercop-data/h8atom/amd64/lib/libsupercop.a(crypto_stream_chacha20_moon_sse2_64_constbranchindex-crypto_stream.o): invalid string offset 19932316 >= 268 for section `.strtab'
try.c: collect2: error: ld returned 1 exit status

Number of similar (compiler,implementation) pairs: 1, namely:
CompilerImplementations
gcc -march=native -mtune=native -O3 -fomit-frame-pointer -fwrapv -fPIC -fPIE avx

Compiler output

Implementation: avx2int
Security model: constbranchindex
Compiler: clang -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
smult.c: smult.c:36:8: error: always_inline function '_mm256_mul_epi32' requires target feature 'avx2', but would be inlined into function 'crypto_scalarmult_kummer_avx2int_constbranchindex_gfe4x_mulconst' that is compiled without support for 'avx2'
smult.c: t0 = _mm256_mul_epi32(a->v[0],*b);
smult.c: ^
smult.c: smult.c:36:8: error: AVX vector argument of type '__m256i' (vector of 4 'long long' values) without 'avx' enabled changes the ABI
smult.c: smult.c:37:8: error: always_inline function '_mm256_mul_epi32' requires target feature 'avx2', but would be inlined into function 'crypto_scalarmult_kummer_avx2int_constbranchindex_gfe4x_mulconst' that is compiled without support for 'avx2'
smult.c: t1 = _mm256_mul_epi32(a->v[1],*b);
smult.c: ^
smult.c: smult.c:37:8: error: AVX vector argument of type '__m256i' (vector of 4 'long long' values) without 'avx' enabled changes the ABI
smult.c: smult.c:38:30: error: always_inline function '_mm256_srli_epi64' requires target feature 'avx2', but would be inlined into function 'crypto_scalarmult_kummer_avx2int_constbranchindex_gfe4x_mulconst' that is compiled without support for 'avx2'
smult.c: t1 = _mm256_add_epi64(t1,_mm256_srli_epi64(t0,26)); t0 &= mask26;
smult.c: ^
smult.c: smult.c:38:30: error: AVX vector argument of type '__m256i' (vector of 4 'long long' values) without 'avx' enabled changes the ABI
smult.c: smult.c:38:10: error: always_inline function '_mm256_add_epi64' requires target feature 'avx2', but would be inlined into function 'crypto_scalarmult_kummer_avx2int_constbranchindex_gfe4x_mulconst' that is compiled without support for 'avx2'
smult.c: t1 = _mm256_add_epi64(t1,_mm256_srli_epi64(t0,26)); t0 &= mask26;
smult.c: ^
smult.c: smult.c:38:10: error: AVX vector argument of type '__m256i' (vector of 4 'long long' values) without 'avx' enabled changes the ABI
smult.c: smult.c:39:8: error: always_inline function '_mm256_mul_epi32' requires target feature 'avx2', but would be inlined into function 'crypto_scalarmult_kummer_avx2int_constbranchindex_gfe4x_mulconst' that is compiled without support for 'avx2'
smult.c: t2 = _mm256_mul_epi32(a->v[2],*b);
smult.c: ^
smult.c: smult.c:39:8: error: AVX vector argument of type '__m256i' (vector of 4 'long long' values) without 'avx' enabled changes the ABI
smult.c: smult.c:40:8: error: always_inline function '_mm256_mul_epi32' requires target feature 'avx2', but would be inlined into function 'crypto_scalarmult_kummer_avx2int_constbranchindex_gfe4x_mulconst' that is compiled without support for 'avx2'
smult.c: t3 = _mm256_mul_epi32(a->v[3],*b);
smult.c: ^
smult.c: smult.c:40:8: error: AVX vector argument of type '__m256i' (vector of 4 'long long' values) without 'avx' enabled changes the ABI
smult.c: smult.c:41:8: error: always_inline function '_mm256_mul_epi32' requires target feature 'avx2', but would be inlined into function 'crypto_scalarmult_kummer_avx2int_constbranchindex_gfe4x_mulconst' that is compiled without support for 'avx2'
smult.c: ...

Number of similar (compiler,implementation) pairs: 5, namely:
CompilerImplementations
clang -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2int
clang -march=native -O3 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2int
clang -march=native -O -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2int
clang -march=native -Os -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2int
clang -mcpu=native -O3 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2int

Compiler output

Implementation: avx2int
Security model: constbranchindex
Compiler: gcc -march=native -mtune=native -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE
smult.c: smult.c: In function 'crypto_scalarmult_kummer_avx2int_constbranchindex_gfe4x_mulconst':
smult.c: smult.c:36:6: warning: AVX vector return without AVX enabled changes the ABI [-Wpsabi]
smult.c: 36 | t0 = _mm256_mul_epi32(a->v[0],*b);
smult.c: | ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
smult.c: In file included from /usr/lib/gcc/x86_64-linux-gnu/11/include/immintrin.h:47,
smult.c: from gfe4x.h:5,
smult.c: from smult.c:3:
smult.c: /usr/lib/gcc/x86_64-linux-gnu/11/include/avx2intrin.h:126:1: error: inlining failed in call to 'always_inline' '_mm256_add_epi64': target specific option mismatch
smult.c: 126 | _mm256_add_epi64 (__m256i __A, __m256i __B)
smult.c: | ^~~~~~~~~~~~~~~~
smult.c: smult.c:45:10: note: called from here
smult.c: 45 | t2 = _mm256_add_epi64(t2,_mm256_srli_epi64(t1,25)); t1 &= mask25;
smult.c: | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
smult.c: In file included from /usr/lib/gcc/x86_64-linux-gnu/11/include/immintrin.h:47,
smult.c: from gfe4x.h:5,
smult.c: from smult.c:3:
smult.c: /usr/lib/gcc/x86_64-linux-gnu/11/include/avx2intrin.h:787:1: error: inlining failed in call to 'always_inline' '_mm256_srli_epi64': target specific option mismatch
smult.c: 787 | _mm256_srli_epi64 (__m256i __A, int __B)
smult.c: | ^~~~~~~~~~~~~~~~~
smult.c: smult.c:45:10: note: called from here
smult.c: 45 | t2 = _mm256_add_epi64(t2,_mm256_srli_epi64(t1,25)); t1 &= mask25;
smult.c: | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
smult.c: In file included from /usr/lib/gcc/x86_64-linux-gnu/11/include/immintrin.h:47,
smult.c: from gfe4x.h:5,
smult.c: from smult.c:3:
smult.c: ...

Number of similar (compiler,implementation) pairs: 4, namely:
CompilerImplementations
gcc -march=native -mtune=native -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE avx2int
gcc -march=native -mtune=native -O3 -fomit-frame-pointer -fwrapv -fPIC -fPIE avx2int
gcc -march=native -mtune=native -O -fomit-frame-pointer -fwrapv -fPIC -fPIE avx2int
gcc -march=native -mtune=native -Os -fomit-frame-pointer -fwrapv -fPIC -fPIE avx2int