Implementation notes: amd64, r24000, crypto_kem/titaniumccahi

Computer: r24000
Microarchitecture: amd64; Coffee Lake (906ea)
Architecture: amd64
CPU ID: GenuineIntel-000906ea-bfebfbff
SUPERCOP version: 20240107
Operation: crypto_kem
Primitive: titaniumccahi
TimeObject sizeTest sizeImplementationCompilerBenchmark dateSUPERCOP version
3428855108367 0 0274150 828 1832T:avx2gcc_-march=native_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011920240107
3522576108495 0 0271782 828 1832T:avx2gcc_-march=native_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011920240107
3751285108406 0 0271494 828 1832T:avx2gcc_-march=native_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011920240107
4449480115144 0 0279207 828 1784T:optclang_-march=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011920240107
447663293368 0 0257975 828 1784T:optclang_-march=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011920240107
449686393368 0 0257975 828 1784T:optclang_-march=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011920240107
459735473880 0 0238639 828 1784T:optclang_-mcpu=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011920240107
471023656342 0 0218425 820 1784T:optclang_-march=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011920240107
479051276612 0 0242294 828 1832T:optgcc_-march=native_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011920240107
487329856618 0 0220054 828 1832T:optgcc_-march=native_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011920240107
547855257447 0 0220750 828 1832T:optgcc_-march=native_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011920240107
80106176757463 0 0222783 828 1784T:refclang_-march=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011920240107
80107096686207 0 0251487 828 1784T:refclang_-march=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011920240107
80114393157463 0 0222783 828 1784T:refclang_-march=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011920240107
81043553061809 0 0226511 828 1784T:refclang_-mcpu=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011920240107
82716128944609 0 0206713 820 1784T:refclang_-march=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011920240107
83624091955970 0 0221694 828 1832T:refgcc_-march=native_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011920240107
83958958643944 0 0207262 828 1832T:refgcc_-march=native_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011920240107
92784163944270 0 0207398 828 1832T:refgcc_-march=native_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011920240107

Compiler output

Implementation: T:avx2
Security model: timingleaks
Compiler: clang -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
encrypt.c: In file included from encrypt.c:18:
encrypt.c: In file included from /usr/lib/llvm-10/lib/clang/10.0.0/include/x86intrin.h:13:
encrypt.c: /usr/lib/llvm-10/lib/clang/10.0.0/include/ia32intrin.h:210:16: error: expected identifier or '('
encrypt.c: unsigned int D;
encrypt.c: ^
encrypt.c: ./param.h:28:11: note: expanded from macro 'D'
encrypt.c: #define D 256
encrypt.c: ^
encrypt.c: In file included from encrypt.c:18:
encrypt.c: In file included from /usr/lib/llvm-10/lib/clang/10.0.0/include/x86intrin.h:13:
encrypt.c: /usr/lib/llvm-10/lib/clang/10.0.0/include/ia32intrin.h:211:20: error: cannot take the address of an rvalue of type 'int'
encrypt.c: __builtin_memcpy(&D, &__A, sizeof(__A));
encrypt.c: ^~
encrypt.c: /usr/lib/llvm-10/lib/clang/10.0.0/include/ia32intrin.h:227:22: error: expected identifier or '('
encrypt.c: unsigned long long D;
encrypt.c: ^
encrypt.c: ./param.h:28:11: note: expanded from macro 'D'
encrypt.c: #define D 256
encrypt.c: ^
encrypt.c: In file included from encrypt.c:18:
encrypt.c: In file included from /usr/lib/llvm-10/lib/clang/10.0.0/include/x86intrin.h:13:
encrypt.c: /usr/lib/llvm-10/lib/clang/10.0.0/include/ia32intrin.h:228:20: error: cannot take the address of an rvalue of type 'int'
encrypt.c: __builtin_memcpy(&D, &__A, sizeof(__A));
encrypt.c: ^~
encrypt.c: /usr/lib/llvm-10/lib/clang/10.0.0/include/ia32intrin.h:244:9: error: expected identifier or '('
encrypt.c: ...

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

Compiler output

Implementation: T:avx2
Security model: timingleaks
Compiler: gcc -march=native -mtune=native -Os -fomit-frame-pointer -fwrapv -fPIC -fPIE
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(sampler.o): in function `sampler_zq':
try.c: sampler.c:(.text+0x...): undefined reference to `load_24'
try.c: /usr/bin/ld: sampler.c:(.text+0x...): undefined reference to `barrett_zq'
try.c: collect2: error: ld returned 1 exit status

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

Compiler output

Implementation: T:opt
Security model: timingleaks
Compiler: gcc -march=native -mtune=native -Os -fomit-frame-pointer -fwrapv -fPIC -fPIE
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(encrypt.o): in function `crypto_encrypt_keypair':
try.c: encrypt.c:(.text+0x...): undefined reference to `barrett_4q2'
try.c: /usr/bin/ld: encrypt.c:(.text+0x...): undefined reference to `barrett_4q'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(encrypt.o): in function `crypto_encrypt':
try.c: encrypt.c:(.text+0x...): undefined reference to `barrett_4q2'
try.c: /usr/bin/ld: encrypt.c:(.text+0x...): undefined reference to `barrett_4q2'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(encrypt.o): in function `crypto_encrypt_open':
try.c: encrypt.c:(.text+0x...): undefined reference to `barrett_4q2'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(fastrandombytes.o): in function `fastrandombytes':
try.c: fastrandombytes.c:(.text+0x...): undefined reference to `load_32'
try.c: /usr/bin/ld: fastrandombytes.c:(.text+0x...): undefined reference to `store_32'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(ntt.o): in function `ntt_butterfly_1536_2560':
try.c: ntt.c:(.text+0x...): undefined reference to `barrett_16q'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(ntt.o): in function `ntt_butterfly_2560_1024':
try.c: ntt.c:(.text+0x...): undefined reference to `barrett_32q'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(ntt.o): in function `ntt_butterfly_768_2304':
try.c: ntt.c:(.text+0x...): undefined reference to `barrett_8q'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(ntt.o): in function `ntt_butterfly_1536_2304':
try.c: ntt.c:(.text+0x...): undefined reference to `barrett_16q'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(ntt.o): in function `ntt_butterfly_2304_2304_inv':
try.c: ntt.c:(.text+0x...): undefined reference to `barrett_32q'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(ntt.o): in function `ntt_butterfly_1024_1024_inv':
try.c: ntt.c:(.text+0x...): undefined reference to `barrett_8q'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(ntt.o): in function `ntt_butterfly_768_1024':
try.c: ntt.c:(.text+0x...): undefined reference to `barrett_8q'
try.c: ...

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

Compiler output

Implementation: T:ref
Security model: timingleaks
Compiler: gcc -march=native -mtune=native -Os -fomit-frame-pointer -fwrapv -fPIC -fPIE
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(fastrandombytes.o): in function `fastrandombytes':
try.c: fastrandombytes.c:(.text+0x...): undefined reference to `load_32'
try.c: /usr/bin/ld: fastrandombytes.c:(.text+0x...): undefined reference to `store_32'
try.c: /usr/bin/ld: libcrypto_kem_titaniumccahi.a(sampler.o): in function `sampler_zq':
try.c: sampler.c:(.text+0x...): undefined reference to `load_24'
try.c: collect2: error: ld returned 1 exit status

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

Namespace violations

Implementation: T:avx2
Security model: timingleaks
Compiler: gcc -march=native -mtune=native -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE
encrypt.o crypto_encrypt T
encrypt.o crypto_encrypt_keypair T
encrypt.o crypto_encrypt_open T
fastrandombytes.o fastrandombytes T
fastrandombytes.o fastrandombytes_setseed T
fastrandombytes.o iv C
fastrandombytes.o key C
ntt.o intt_1024_256 T
ntt.o intt_2304_2304_inv T
ntt.o intt_2560_1024 T
ntt.o intt_2560_256 T
ntt.o ntt_1024_1024_inv T
ntt.o ntt_1536_2304 T
ntt.o ntt_1536_2560 T
ntt.o ntt_2304_2560 T
ntt.o ntt_768_1024 T
ntt.o ntt_768_2304 T
pack.o poly_decode T
pack.o poly_decode_c2 T
pack.o poly_encode T
pack.o poly_encode_c2 T
sampler.o sampler_binomial T
sampler.o sampler_zb T
sampler.o sampler_zq T

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

Namespace violations

Implementation: T:ref
Security model: timingleaks
Compiler: clang -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
encrypt.o crypto_encrypt T
encrypt.o crypto_encrypt_keypair T
encrypt.o crypto_encrypt_open T
fastrandombytes.o fastrandombytes T
fastrandombytes.o fastrandombytes_setseed T
fastrandombytes.o iv C
fastrandombytes.o key C
ntt.o intt_1024_1024 T
ntt.o intt_2304_2304_inv T
ntt.o intt_2560_2560 T
ntt.o ntt_1024_1024_inv T
ntt.o ntt_2304_2304 T
pack.o poly_decode T
pack.o poly_decode_c2 T
pack.o poly_encode T
pack.o poly_encode_c2 T
product.o mp T
product.o product T
sampler.o sampler_binomial T
sampler.o sampler_zb T
sampler.o sampler_zq T

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