Implementation notes: amd64, gcc67, crypto_dh/claus

Computer: gcc67
Architecture: amd64
CPU ID: AuthenticAMD-00810f10-178bfbff
SUPERCOP version: 20210125
Operation: crypto_dh
Primitive: claus
TimeObject sizeTest sizeImplementationCompilerBenchmark dateSUPERCOP version
47882822983 16 0217552 1108 1744T:gmpclang++_-march=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021011620210114
47896242475 16 0219759 1100 1776T:gmpclang++_-march=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021011620210114
47909541921 16 0219732 1116 1840T:gmpg++_-march=native_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021011620210114
47957321859 16 0217707 1116 1840T:gmpg++_-march=native_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021011620210114
47958132475 16 0218855 1100 1776T:gmpclang++_-march=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021011620210114
48510883772 336 2414612 3124 3696T:ntlg++_-march=native_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021011620210114
48542062739 336 2413001 3068 3664T:ntlg++_-march=native_-mtune=native_-Os_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021011620210114
48543614320 336 2414243 3068 3632T:ntlclang++_-march=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021011620210114
48544533898 336 2414315 3124 3696T:ntlg++_-march=native_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021011620210114
48563693776 336 2416540 3124 3696T:ntlg++_-march=native_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021011620210114
48595374004 336 2412104 3060 3632T:ntlclang++_-march=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021011620210114
48595694320 336 2415147 3068 3632T:ntlclang++_-march=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021011620210114
48993952475 16 0218855 1100 1776T:gmpclang++_-march=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021011620210114
57601771800 16 0216198 1108 1808T:gmpg++_-march=native_-mtune=native_-Os_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021011620210114
61146224320 336 2414243 3068 3632T:ntlclang++_-march=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2021011620210114
70943241896 16 0217477 1116 1840T:gmpg++_-march=native_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2021011620210114

Compiler output

Implementation: T:cryptopp
Security model: timingleaks
Compiler: clang++ -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
keypair.cpp: keypair.cpp:1:10: fatal error: 'cryptopp/dh.h' file not found
keypair.cpp: #include <cryptopp/dh.h>
keypair.cpp: ^
keypair.cpp: 1 error generated.

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

Compiler output

Implementation: T:cryptopp
Security model: timingleaks
Compiler: g++ -march=native -mtune=native -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE
keypair.cpp: keypair.cpp:1:25: fatal error: cryptopp/dh.h: No such file or directory
keypair.cpp: #include <cryptopp/dh.h>
keypair.cpp: ^
keypair.cpp: compilation terminated.

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

Compiler output

Implementation: T:openssl
Security model: timingleaks
Compiler: clang -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
keypair.c: keypair.c:25:5: error: incomplete definition of type 'struct dh_st'
keypair.c: dh->p = BN_new(); if (!dh->p) goto error;
keypair.c: ~~^
keypair.c: /usr/include/openssl/ossl_typ.h:104:16: note: forward declaration of 'struct dh_st'
keypair.c: typedef struct dh_st DH;
keypair.c: ^
keypair.c: keypair.c:25:28: error: incomplete definition of type 'struct dh_st'
keypair.c: dh->p = BN_new(); if (!dh->p) goto error;
keypair.c: ~~^
keypair.c: /usr/include/openssl/ossl_typ.h:104:16: note: forward declaration of 'struct dh_st'
keypair.c: typedef struct dh_st DH;
keypair.c: ^
keypair.c: keypair.c:26:5: error: incomplete definition of type 'struct dh_st'
keypair.c: dh->g = BN_new(); if (!dh->g) goto error;
keypair.c: ~~^
keypair.c: /usr/include/openssl/ossl_typ.h:104:16: note: forward declaration of 'struct dh_st'
keypair.c: typedef struct dh_st DH;
keypair.c: ^
keypair.c: keypair.c:26:28: error: incomplete definition of type 'struct dh_st'
keypair.c: dh->g = BN_new(); if (!dh->g) goto error;
keypair.c: ~~^
keypair.c: /usr/include/openssl/ossl_typ.h:104:16: note: forward declaration of 'struct dh_st'
keypair.c: typedef struct dh_st DH;
keypair.c: ^
keypair.c: keypair.c:28:39: error: incomplete definition of type 'struct dh_st'
keypair.c: ...

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

Compiler output

Implementation: T:openssl
Security model: timingleaks
Compiler: gcc -march=native -mtune=native -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE
keypair.c: keypair.c: In function 'crypto_dh_claus_openssl_timingleaks_keypair':
keypair.c: keypair.c:25:5: error: dereferencing pointer to incomplete type 'DH {aka struct dh_st}'
keypair.c: dh->p = BN_new(); if (!dh->p) goto error;
keypair.c: ^~

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

Compiler output

Implementation: T:opensslnew
Security model: timingleaks
Compiler: clang -march=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
keypair.c: keypair.c:39:7: warning: implicit declaration of function 'DH_get0_pub_key' is invalid in C99 [-Wimplicit-function-declaration]
keypair.c: z = DH_get0_pub_key(dh);
keypair.c: ^
keypair.c: keypair.c:39:5: warning: incompatible integer to pointer conversion assigning to 'const BIGNUM *' (aka 'const struct bignum_st *') from 'int' [-Wint-conversion]
keypair.c: z = DH_get0_pub_key(dh);
keypair.c: ^ ~~~~~~~~~~~~~~~~~~~
keypair.c: keypair.c:46:7: warning: implicit declaration of function 'DH_get0_priv_key' is invalid in C99 [-Wimplicit-function-declaration]
keypair.c: z = DH_get0_priv_key(dh);
keypair.c: ^
keypair.c: keypair.c:46:5: warning: incompatible integer to pointer conversion assigning to 'const BIGNUM *' (aka 'const struct bignum_st *') from 'int' [-Wint-conversion]
keypair.c: z = DH_get0_priv_key(dh);
keypair.c: ^ ~~~~~~~~~~~~~~~~~~~~
keypair.c: 4 warnings generated.
try.c: crypto_dh_claus.a(keypair.o): In function `crypto_dh_claus_opensslnew_timingleaks_keypair':
try.c: keypair.c:(.text+0x...): undefined reference to `DH_get0_pub_key'
try.c: keypair.c:(.text+0x...): undefined reference to `DH_get0_priv_key'
try.c: clang: error: linker command failed with exit code 1 (use -v to see invocation)

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

Compiler output

Implementation: T:opensslnew
Security model: timingleaks
Compiler: gcc -march=native -mtune=native -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE
keypair.c: keypair.c: In function 'crypto_dh_claus_opensslnew_timingleaks_keypair':
keypair.c: keypair.c:39:7: warning: implicit declaration of function 'DH_get0_pub_key' [-Wimplicit-function-declaration]
keypair.c: z = DH_get0_pub_key(dh);
keypair.c: ^~~~~~~~~~~~~~~
keypair.c: keypair.c:39:5: warning: assignment makes pointer from integer without a cast [-Wint-conversion]
keypair.c: z = DH_get0_pub_key(dh);
keypair.c: ^
keypair.c: keypair.c:46:7: warning: implicit declaration of function 'DH_get0_priv_key' [-Wimplicit-function-declaration]
keypair.c: z = DH_get0_priv_key(dh);
keypair.c: ^~~~~~~~~~~~~~~~
keypair.c: keypair.c:46:5: warning: assignment makes pointer from integer without a cast [-Wint-conversion]
keypair.c: z = DH_get0_priv_key(dh);
keypair.c: ^
try.c: crypto_dh_claus.a(keypair.o): In function `crypto_dh_claus_opensslnew_timingleaks_keypair':
try.c: keypair.c:(.text+0x...): undefined reference to `DH_get0_pub_key'
try.c: keypair.c:(.text+0x...): undefined reference to `DH_get0_priv_key'
try.c: collect2: error: ld returned 1 exit status

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