Implementation notes: amd64, margaux, crypto_sign/dilithium3

Computer: margaux
Architecture: amd64
CPU ID: GenuineIntel-000006fb-bfebfbff
SUPERCOP version: 20210604
Operation: crypto_sign
Primitive: dilithium3
TimeObject sizeTest sizeImplementationCompilerBenchmark dateSUPERCOP version
207632737728 0 058540 812 1736refclang_-march=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021050420210423
208092338192 0 058788 812 1736refclang_-mcpu=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021050420210423
234404926015 0 045476 812 1736refclang_-march=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021050420210423
234501926015 0 045476 812 1736refclang_-march=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021050420210423
252526118680 0 036042 804 1736refclang_-march=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021050420210423
259789848314 0 069745 812 1768refgcc_-march=native_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021050420210423
264001617963 0 035985 804 1736refgcc_-march=native_-mtune=native_-Os_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021050420210423
266388620210 0 039473 812 1768refgcc_-march=native_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021050420210423
282079819310 0 038353 812 1768refgcc_-march=native_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021050420210423

Compiler output

Implementation: avx2
Security model: constbranchindex
Compiler: clang -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
fips202x4.c: fips202x4.c:22:12: error: always_inline function '_mm256_setzero_si256' requires target feature 'xsave', but would be inlined into function 'keccakx4_absorb_once' that is compiled without support for 'xsave'
fips202x4.c: s[i] = _mm256_setzero_si256();
fips202x4.c: ^
fips202x4.c: fips202x4.c:24:9: error: always_inline function '_mm256_set_epi64x' requires target feature 'xsave', but would be inlined into function 'keccakx4_absorb_once' that is compiled without support for 'xsave'
fips202x4.c: idx = _mm256_set_epi64x((long long)in3, (long long)in2, (long long)in1, (long long)in0);
fips202x4.c: ^
fips202x4.c: fips202x4.c:27:11: error: '__builtin_ia32_gatherq_q256' needs target feature avx2
fips202x4.c: t = _mm256_i64gather_epi64((long long *)pos, idx, 1);
fips202x4.c: ^
fips202x4.c: /usr/lib/llvm-6.0/lib/clang/6.0.0/include/avx2intrin.h:1301:12: note: expanded from macro '_mm256_i64gather_epi64'
fips202x4.c: (__m256i)__builtin_ia32_gatherq_q256((__v4di)_mm256_undefined_si256(), \
fips202x4.c: ^
fips202x4.c: fips202x4.c:27:11: error: always_inline function '_mm256_undefined_si256' requires target feature 'xsave', but would be inlined into function 'keccakx4_absorb_once' that is compiled without support for 'xsave'
fips202x4.c: /usr/lib/llvm-6.0/lib/clang/6.0.0/include/avx2intrin.h:1301:48: note: expanded from macro '_mm256_i64gather_epi64'
fips202x4.c: (__m256i)__builtin_ia32_gatherq_q256((__v4di)_mm256_undefined_si256(), \
fips202x4.c: ^
fips202x4.c: fips202x4.c:27:11: error: always_inline function '_mm256_set1_epi64x' requires target feature 'xsave', but would be inlined into function 'keccakx4_absorb_once' that is compiled without support for 'xsave'
fips202x4.c: /usr/lib/llvm-6.0/lib/clang/6.0.0/include/avx2intrin.h:1304:48: note: expanded from macro '_mm256_i64gather_epi64'
fips202x4.c: (__v4di)_mm256_set1_epi64x(-1), (s)); })
fips202x4.c: ^
fips202x4.c: fips202x4.c:28:14: error: always_inline function '_mm256_xor_si256' requires target feature 'xsave', but would be inlined into function 'keccakx4_absorb_once' that is compiled without support for 'xsave'
fips202x4.c: s[i] = _mm256_xor_si256(s[i], t);
fips202x4.c: ^
fips202x4.c: fips202x4.c:37:9: error: '__builtin_ia32_gatherq_q256' needs target feature avx2
fips202x4.c: t = _mm256_i64gather_epi64((long long *)pos, idx, 1);
fips202x4.c: ...

Number of similar (compiler,implementation) pairs: 4, namely:
CompilerImplementations
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

Compiler output

Implementation: avx2
Security model: constbranchindex
Compiler: clang -mcpu=native -O3 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
fips202x4.c: fips202x4.c:22:12: error: always_inline function '_mm256_setzero_si256' requires target feature 'sse4.2', but would be inlined into function 'keccakx4_absorb_once' that is compiled without support for 'sse4.2'
fips202x4.c: s[i] = _mm256_setzero_si256();
fips202x4.c: ^
fips202x4.c: fips202x4.c:24:9: error: always_inline function '_mm256_set_epi64x' requires target feature 'sse4.2', but would be inlined into function 'keccakx4_absorb_once' that is compiled without support for 'sse4.2'
fips202x4.c: idx = _mm256_set_epi64x((long long)in3, (long long)in2, (long long)in1, (long long)in0);
fips202x4.c: ^
fips202x4.c: fips202x4.c:27:11: error: '__builtin_ia32_gatherq_q256' needs target feature avx2
fips202x4.c: t = _mm256_i64gather_epi64((long long *)pos, idx, 1);
fips202x4.c: ^
fips202x4.c: /usr/lib/llvm-6.0/lib/clang/6.0.0/include/avx2intrin.h:1301:12: note: expanded from macro '_mm256_i64gather_epi64'
fips202x4.c: (__m256i)__builtin_ia32_gatherq_q256((__v4di)_mm256_undefined_si256(), \
fips202x4.c: ^
fips202x4.c: fips202x4.c:27:11: error: always_inline function '_mm256_undefined_si256' requires target feature 'sse4.2', but would be inlined into function 'keccakx4_absorb_once' that is compiled without support for 'sse4.2'
fips202x4.c: /usr/lib/llvm-6.0/lib/clang/6.0.0/include/avx2intrin.h:1301:48: note: expanded from macro '_mm256_i64gather_epi64'
fips202x4.c: (__m256i)__builtin_ia32_gatherq_q256((__v4di)_mm256_undefined_si256(), \
fips202x4.c: ^
fips202x4.c: fips202x4.c:27:11: error: always_inline function '_mm256_set1_epi64x' requires target feature 'sse4.2', but would be inlined into function 'keccakx4_absorb_once' that is compiled without support for 'sse4.2'
fips202x4.c: /usr/lib/llvm-6.0/lib/clang/6.0.0/include/avx2intrin.h:1304:48: note: expanded from macro '_mm256_i64gather_epi64'
fips202x4.c: (__v4di)_mm256_set1_epi64x(-1), (s)); })
fips202x4.c: ^
fips202x4.c: fips202x4.c:28:14: error: always_inline function '_mm256_xor_si256' requires target feature 'avx2', but would be inlined into function 'keccakx4_absorb_once' that is compiled without support for 'avx2'
fips202x4.c: s[i] = _mm256_xor_si256(s[i], t);
fips202x4.c: ^
fips202x4.c: fips202x4.c:37:9: error: '__builtin_ia32_gatherq_q256' needs target feature avx2
fips202x4.c: t = _mm256_i64gather_epi64((long long *)pos, idx, 1);
fips202x4.c: ...

Number of similar (compiler,implementation) pairs: 1, namely:
CompilerImplementations
clang -mcpu=native -O3 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE avx2

Compiler output

Implementation: avx2
Security model: constbranchindex
Compiler: gcc -march=native -mtune=native -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE
fips202x4.c: fips202x4.c: In function 'keccakx4_absorb_once':
fips202x4.c: fips202x4.c:22:10: warning: AVX vector return without AVX enabled changes the ABI [-Wpsabi]
fips202x4.c: s[i] = _mm256_setzero_si256();
fips202x4.c: ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
fips202x4.c: In file included from /usr/lib/gcc/x86_64-linux-gnu/7/include/immintrin.h:41:0,
fips202x4.c: from fips202x4.c:3:
fips202x4.c: /usr/lib/gcc/x86_64-linux-gnu/7/include/avxintrin.h:1235:1: error: inlining failed in call to always_inline '_mm256_setzero_si256': target specific option mismatch
fips202x4.c: _mm256_setzero_si256 (void)
fips202x4.c: ^~~~~~~~~~~~~~~~~~~~
fips202x4.c: fips202x4.c:22:12: note: called from here
fips202x4.c: s[i] = _mm256_setzero_si256();
fips202x4.c: ^~~~~~~~~~~~~~~~~~~~~~
fips202x4.c: In file included from /usr/lib/gcc/x86_64-linux-gnu/7/include/immintrin.h:41:0,
fips202x4.c: from fips202x4.c:3:
fips202x4.c: /usr/lib/gcc/x86_64-linux-gnu/7/include/avxintrin.h:1296:1: error: inlining failed in call to always_inline '_mm256_set_epi64x': target specific option mismatch
fips202x4.c: _mm256_set_epi64x (long long __A, long long __B, long long __C,
fips202x4.c: ^~~~~~~~~~~~~~~~~
fips202x4.c: fips202x4.c:24:7: note: called from here
fips202x4.c: idx = _mm256_set_epi64x((long long)in3, (long long)in2, (long long)in1, (long long)in0);
fips202x4.c: ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
fips202x4.c: In file included from /usr/lib/gcc/x86_64-linux-gnu/7/include/immintrin.h:43:0,
fips202x4.c: from fips202x4.c:3:
fips202x4.c: /usr/lib/gcc/x86_64-linux-gnu/7/include/avx2intrin.h:913:1: error: inlining failed in call to always_inline '_mm256_xor_si256': target specific option mismatch
fips202x4.c: _mm256_xor_si256 (__m256i __A, __m256i __B)
fips202x4.c: ^~~~~~~~~~~~~~~~
fips202x4.c: ...

Number of similar (compiler,implementation) pairs: 4, namely:
CompilerImplementations
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