Implementation notes: amd64, speed2supercop, crypto_kem/mceliece460896pcf

Computer: speed2supercop
Microarchitecture: amd64; Haswell+AES (306c3)
Architecture: amd64
CPU ID: GenuineIntel-000306c3-1fc9cbf5
SUPERCOP version: 20240625
Operation: crypto_kem
Primitive: mceliece460896pcf
TimeObject sizeTest sizeImplementationCompilerBenchmark dateSUPERCOP version
337548135636 0 0184349 760 1600avxgcc_-march=native_-mtune=native_-O3_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
343116144896 0 0195037 816 1568avxclang_-march=native_-O3_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
344996123508 0 0173525 816 1568avxclang_-march=native_-O2_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
37271687820 0 0134693 760 1600avxgcc_-march=native_-mtune=native_-O2_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
37288889755 0 0136189 808 1568avxclang_-march=native_-O_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
37407284954 0 0131799 800 1632avxclang_-march=native_-Os_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
49900085006 0 0131509 760 1600avxgcc_-march=native_-mtune=native_-O_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
525152127033 0 0174493 800 1568sseclang_-march=native_-O3_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
525512111289 0 0158525 800 1568sseclang_-march=native_-O2_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
565184160400 0 0207557 760 1600ssegcc_-march=native_-mtune=native_-O3_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
56961275856 0 0120583 792 1632sseclang_-march=native_-Os_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
58804881759 0 0125453 800 1568sseclang_-march=native_-O_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
60637284267 0 0129437 760 1600ssegcc_-march=native_-mtune=native_-O2_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
78861280048 0 0125324 752 1568avxgcc_-march=native_-mtune=native_-Os_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
142169692783 0 0142221 800 1568vecclang_-mcpu=native_-O3_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
151059294694 0 0145485 800 1568vecclang_-march=native_-O3_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
183210488974 0 0138213 760 1600vecgcc_-march=native_-mtune=native_-O3_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
227839647388 0 094637 808 1568vecclang_-march=native_-O_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
228560078125 0 0128757 800 1568vecclang_-march=native_-O2_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
245994452341 0 099749 760 1600vecgcc_-march=native_-mtune=native_-O2_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
290134038449 0 084684 752 1568vecgcc_-march=native_-mtune=native_-Os_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
294793248455 0 095645 760 1600vecgcc_-march=native_-mtune=native_-O_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
303555247432 0 094855 800 1632vecclang_-march=native_-Os_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
4050774877184 0 0121925 760 1600ssegcc_-march=native_-mtune=native_-O_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
4096003273138 0 0116796 752 1568ssegcc_-march=native_-mtune=native_-Os_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
15375163634449 0 083181 800 1568refclang_-march=native_-O2_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
15794094845450 0 093191 808 1568refclang_-mcpu=native_-O3_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
16110836854920 0 0103797 800 1568refclang_-march=native_-O3_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
16832550016660 0 062377 800 1632refclang_-march=native_-Os_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
19374648033390 0 081007 768 1600refgcc_-march=native_-mtune=native_-O3_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
19530264815550 0 060693 800 1568refclang_-march=native_-O_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
20075510017140 0 062791 768 1600refgcc_-march=native_-mtune=native_-O2_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
21027793215580 0 060789 760 1600refgcc_-march=native_-mtune=native_-O_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625
23126032811984 0 056094 760 1568refgcc_-march=native_-mtune=native_-Os_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024071120240625

Compiler output


bm.c: bm.c:78:37: warning: AVX vector return of type 'vec256' (aka '__m256i') without 'avx' enabled changes the ABI [-Wpsabi]
bm.c:         for (i = 13; i < 16; i++) buf[i] = vec256_setzero();
bm.c:                                            ^
bm.c: bm.c:80:15: warning: AVX vector return of type 'vec256' (aka '__m256i') without 'avx' enabled changes the ABI [-Wpsabi]
bm.c:         mask[0][0] = vec256_set1_16b(0x5555);
bm.c:                      ^
bm.c: bm.c:81:15: warning: AVX vector return of type 'vec256' (aka '__m256i') without 'avx' enabled changes the ABI [-Wpsabi]
bm.c:         mask[0][1] = vec256_set1_16b(0xAAAA);
bm.c:                      ^
bm.c: bm.c:82:15: warning: AVX vector return of type 'vec256' (aka '__m256i') without 'avx' enabled changes the ABI [-Wpsabi]
bm.c:         mask[1][0] = vec256_set1_16b(0x3333);
bm.c:                      ^
bm.c: bm.c:83:15: warning: AVX vector return of type 'vec256' (aka '__m256i') without 'avx' enabled changes the ABI [-Wpsabi]
bm.c:         mask[1][1] = vec256_set1_16b(0xCCCC);
bm.c:                      ^
bm.c: bm.c:84:15: warning: AVX vector return of type 'vec256' (aka '__m256i') without 'avx' enabled changes the ABI [-Wpsabi]
bm.c:         mask[2][0] = vec256_set1_16b(0x0F0F);
bm.c:                      ^
bm.c: bm.c:85:15: warning: AVX vector return of type 'vec256' (aka '__m256i') without 'avx' enabled changes the ABI [-Wpsabi]
bm.c:         mask[2][1] = vec256_set1_16b(0xF0F0);
bm.c:                      ^
bm.c: bm.c:86:15: warning: AVX vector return of type 'vec256' (aka '__m256i') without 'avx' enabled changes the ABI [-Wpsabi]
bm.c:         mask[3][0] = vec256_set1_16b(0x00FF);
bm.c:                      ^
bm.c: bm.c:87:15: warning: AVX vector return of type 'vec256' (aka '__m256i') without 'avx' enabled changes the ABI [-Wpsabi]
bm.c: ...

Number of similar (implementation,compiler) pairs: 1, namely:
ImplementationCompiler
avxclang -mcpu=native -O3 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))

Compiler output


decrypt.c: In file included from decrypt.c:9:
decrypt.c: In file included from ./vec128_gf.h:10:
decrypt.c: ./vec128.h:33:9: error: always_inline function '_mm_testz_si128' requires target feature 'sse4.1', but would be inlined into function 'vec128_testz' that is compiled without support for 'sse4.1'
decrypt.c:         return _mm_testz_si128(a, a);
decrypt.c:                ^
decrypt.c: 1 error generated.

Number of similar (implementation,compiler) pairs: 1, namely:
ImplementationCompiler
sseclang -mcpu=native -O3 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))

TIMECOP error (can be valgrind bug)


at 0x...: show_sched_status_wrk (m_libcassert.c:407)
   by 0x...: report_and_quit (m_libcassert.c:478)
   by 0x...: panic (m_libcassert.c:554)
   by 0x...: vgPlain_core_panic_at (m_libcassert.c:559)
   by 0x...: vgPlain_core_panic (m_libcassert.c:564)
   by 0x...: failure_exit (m_translate.c:761)
   by 0x...: vpanic (main_util.c:253)
   by 0x...: private_LibVEX_alloc_OOM (main_util.c:181)
   by 0x...: LibVEX_Alloc_inline (main_util.h:176)
   by 0x...: addHInstr_SLOW (host_generic_regs.c:332)
   by 0x...: emit_instr (host_generic_reg_alloc3.c:302)
   by 0x...: doRegisterAllocation_v3 (host_generic_reg_alloc3.c:1321)
   by 0x...: libvex_BackEnd (main_main.c:1133)
   by 0x...: LibVEX_Translate (main_main.c:1236)
   by 0x...: vgPlain_translate (m_translate.c:1831)
   by 0x...: handle_chain_me (scheduler.c:1166)
   by 0x...: vgPlain_scheduler (scheduler.c:1562)
   by 0x...: thread_wrapper (syswrap-linux.c:102)
   by 0x...: run_a_thread_NORETURN (syswrap-linux.c:155)
sched status:
running_tid=1
Thread 1: status = VgTs_Runnable (lwpid 1056618)
   at 0x...: extract_gf (sk_gen.c:43)
   by 0x...: crypto_kem_mceliece460896pcf_avx_constbranchindex_genpoly_gen (sk_gen.c:153)
   by 0x...: crypto_kem_mceliece460896pcf_avx_constbranchindex_operation_keypair (kem_keypair.c:59)
   by 0x...: crypto_kem_mceliece460896pcf_avx_constbranchindex_keypair (wrap_keypair.c:10)
   by 0x...: test (try.c:126)
   by 0x...: main (try-anything.c:345)
client stack range: [0x1FFEFDE000 0x1FFF000FFF] client SP: 0x1FFEFDF6C0
valgrind stack range: [0x10090EF000 0x10091EEFFF] top usage: 18104 of 1048576
Note: see also the FAQ in the source distribution.
It contains workarounds to several common problems.
In particular, if Valgrind aborted or crashed after
identifying problems in your program, there's a good chance
that fixing those problems will prevent Valgrind aborting or
crashing, especially if it happened in m_mallocfree.c.
If that doesn't help, please report this bug to: www.valgrind.org
In the bug report, send all the above text, the valgrind
version, and what OS and version you are using.  Thanks.

Number of similar (implementation,compiler) pairs: 1, namely:
ImplementationCompiler
avxgcc -march=native -mtune=native -O3 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)

TIMECOP error (can be valgrind bug)


at 0x...: show_sched_status_wrk (m_libcassert.c:407)
   by 0x...: report_and_quit (m_libcassert.c:478)
   by 0x...: panic (m_libcassert.c:554)
   by 0x...: vgPlain_core_panic_at (m_libcassert.c:559)
   by 0x...: vgPlain_core_panic (m_libcassert.c:564)
   by 0x...: failure_exit (m_translate.c:761)
   by 0x...: vpanic (main_util.c:253)
   by 0x...: private_LibVEX_alloc_OOM (main_util.c:181)
   by 0x...: LibVEX_Alloc_inline (main_util.h:176)
   by 0x...: addHInstr_SLOW (host_generic_regs.c:332)
   by 0x...: emit_instr (host_generic_reg_alloc3.c:302)
   by 0x...: doRegisterAllocation_v3 (host_generic_reg_alloc3.c:1321)
   by 0x...: libvex_BackEnd (main_main.c:1133)
   by 0x...: LibVEX_Translate (main_main.c:1236)
   by 0x...: vgPlain_translate (m_translate.c:1831)
   by 0x...: handle_chain_me (scheduler.c:1166)
   by 0x...: vgPlain_scheduler (scheduler.c:1562)
   by 0x...: thread_wrapper (syswrap-linux.c:102)
   by 0x...: run_a_thread_NORETURN (syswrap-linux.c:155)
sched status:
running_tid=1
Thread 1: status = VgTs_Runnable (lwpid 1067184)
   at 0x...: extract_gf (sk_gen.c:43)
   by 0x...: crypto_kem_mceliece460896pcf_sse_constbranchindex_genpoly_gen (sk_gen.c:153)
   by 0x...: crypto_kem_mceliece460896pcf_sse_constbranchindex_operation_keypair (kem_keypair.c:59)
   by 0x...: crypto_kem_mceliece460896pcf_sse_constbranchindex_keypair (wrap_keypair.c:10)
   by 0x...: test (try.c:126)
   by 0x...: main (try-anything.c:345)
client stack range: [0x1FFEFDF000 0x1FFF000FFF] client SP: 0x1FFEFDF6C0
valgrind stack range: [0x10091EF000 0x10092EEFFF] top usage: 18104 of 1048576
Note: see also the FAQ in the source distribution.
It contains workarounds to several common problems.
In particular, if Valgrind aborted or crashed after
identifying problems in your program, there's a good chance
that fixing those problems will prevent Valgrind aborting or
crashing, especially if it happened in m_mallocfree.c.
If that doesn't help, please report this bug to: www.valgrind.org
In the bug report, send all the above text, the valgrind
version, and what OS and version you are using.  Thanks.

Number of similar (implementation,compiler) pairs: 1, namely:
ImplementationCompiler
ssegcc -march=native -mtune=native -O3 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)

Passed TIMECOP


TIMECOP iterations: 1

Number of similar (implementation,compiler) pairs: 32, namely:
ImplementationCompiler
avxclang -march=native -O2 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
avxclang -march=native -O3 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
avxclang -march=native -O -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
avxclang -march=native -Os -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
avxgcc -march=native -mtune=native -O2 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
avxgcc -march=native -mtune=native -O -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
avxgcc -march=native -mtune=native -Os -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
refclang -march=native -O2 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
refclang -march=native -O3 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
refclang -march=native -O -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
refclang -march=native -Os -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
refclang -mcpu=native -O3 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
refgcc -march=native -mtune=native -O2 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
refgcc -march=native -mtune=native -O3 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
refgcc -march=native -mtune=native -O -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
refgcc -march=native -mtune=native -Os -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
sseclang -march=native -O2 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
sseclang -march=native -O3 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
sseclang -march=native -O -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
sseclang -march=native -Os -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
ssegcc -march=native -mtune=native -O2 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
ssegcc -march=native -mtune=native -O -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
ssegcc -march=native -mtune=native -Os -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
vecclang -march=native -O2 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
vecclang -march=native -O3 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
vecclang -march=native -O -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
vecclang -march=native -Os -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
vecclang -mcpu=native -O3 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Debian_Clang_16.0.6_(27+b1))
vecgcc -march=native -mtune=native -O2 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
vecgcc -march=native -mtune=native -O3 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
vecgcc -march=native -mtune=native -O -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)
vecgcc -march=native -mtune=native -Os -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (13.3.0)