Implementation notes: amd64, hydra5, crypto_aead/grain128aead

Computer: hydra5
Microarchitecture: amd64; K10 32nm (300f10)
Architecture: amd64
CPU ID: AuthenticAMD-00300f10-178bfbff
SUPERCOP version: 20240625
Operation: crypto_aead
Primitive: grain128aead
TimeObject sizeTest sizeImplementationCompilerBenchmark dateSUPERCOP version
4828776696 0 023346 884 1024T:opt32clang_-mcpu=native_-O3_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
4832596696 0 023346 884 1024T:opt32clang_-march=native_-O3_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
4959187199 0 022954 884 1024T:opt32clang_-march=native_-O2_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
5624373260 0 017082 804 1056T:opt32gcc_-march=native_-mtune=native_-Os_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
5652776102 0 020362 884 1024T:opt32clang_-march=native_-O_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
5707714199 0 017684 876 1024T:opt32clang_-march=native_-Os_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
5811873747 0 018903 828 1088T:opt32gcc_-march=native_-mtune=native_-O_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
6011629385 0 026663 828 1088T:opt32gcc_-march=native_-mtune=native_-O3_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
7658133965 0 019903 828 1088T:opt32gcc_-march=native_-mtune=native_-O2_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
125895569290 0 125124 892 1024T:refclang_-march=native_-O2_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
126994437249 0 124641 836 1120T:refgcc_-march=native_-mtune=native_-O3_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
1278694315183 0 131900 892 1024T:refclang_-march=native_-O3_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
1279490215183 0 131900 892 1024T:refclang_-mcpu=native_-O3_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
151868004530 0 118110 884 1024T:refclang_-march=native_-Os_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
203102625476 0 121513 836 1120T:refgcc_-march=native_-mtune=native_-O2_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
211859245507 0 119892 892 1024T:refclang_-march=native_-O_-fwrapv_-Qunused-arguments_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
258245153676 0 117620 812 1088T:refgcc_-march=native_-mtune=native_-Os_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625
760691854076 0 119182 820 1120T:refgcc_-march=native_-mtune=native_-O_-fwrapv_-fPIC_-fPIE_-gdwarf-4_-Wall2024062820240625

Compiler output


grain128aead_32p.c: grain128aead_32p.c:78:6: warning: variable 'mstmp' set but not used [-Wunused-but-set-variable]
grain128aead_32p.c:         u16 mstmp = ms;
grain128aead_32p.c:             ^
grain128aead_32p.c: grain128aead_32p.c:111:5: warning: variable 'mstmp' set but not used [-Wunused-but-set-variable]
grain128aead_32p.c:         u8 mstmp = ms;
grain128aead_32p.c:            ^
grain128aead_32p.c: 2 warnings generated.

Number of similar (implementation,compiler) pairs: 5, namely:
ImplementationCompiler
T:opt32clang -march=native -O2 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Ubuntu_Clang_14.0.0)
T:opt32clang -march=native -O3 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Ubuntu_Clang_14.0.0)
T:opt32clang -march=native -O -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Ubuntu_Clang_14.0.0)
T:opt32clang -march=native -Os -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Ubuntu_Clang_14.0.0)
T:opt32clang -mcpu=native -O3 -fwrapv -Qunused-arguments -fPIC -fPIE -gdwarf-4 -Wall (Ubuntu_Clang_14.0.0)

Compiler output


grain128aead_32p.c: grain128aead_32p.c: In function 'crypto_aead_grain128aead_opt32_timingleaks_encrypt':
grain128aead_32p.c: grain128aead_32p.c:275:13: warning: 'rem_word' may be used uninitialized in this function [-Wmaybe-uninitialized]
grain128aead_32p.c:   275 |         u32 rem_word;
grain128aead_32p.c:       |             ^~~~~~~~
grain128aead_32p.c: grain128aead_32p.c: In function 'crypto_aead_grain128aead_opt32_timingleaks_decrypt':
grain128aead_32p.c: grain128aead_32p.c:365:13: warning: 'rem_word' may be used uninitialized in this function [-Wmaybe-uninitialized]
grain128aead_32p.c:   365 |         u32 rem_word;
grain128aead_32p.c:       |             ^~~~~~~~

Number of similar (implementation,compiler) pairs: 2, namely:
ImplementationCompiler
T:opt32gcc -march=native -mtune=native -O2 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (11.4.0)
T:opt32gcc -march=native -mtune=native -O3 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (11.4.0)

Compiler output


grain128aead_32p.c: grain128aead_32p.c: In function 'crypto_aead_grain128aead_opt32_timingleaks_encrypt':
grain128aead_32p.c: grain128aead_32p.c:295:35: warning: 'rem_word' may be used uninitialized in this function [-Wmaybe-uninitialized]
grain128aead_32p.c:   295 |                 *(c + j) = ((u8) (getkb(rem_word) >> 8)) ^ *(m + j);
grain128aead_32p.c:       |                                   ^~~~~~~~~~~~~~~
grain128aead_32p.c: grain128aead_32p.c: In function 'crypto_aead_grain128aead_opt32_timingleaks_decrypt':
grain128aead_32p.c: grain128aead_32p.c:385:35: warning: 'rem_word' may be used uninitialized in this function [-Wmaybe-uninitialized]
grain128aead_32p.c:   385 |                 *(m + j) = ((u8) (getkb(rem_word) >> 8)) ^ *(c + j);
grain128aead_32p.c:       |                                   ^~~~~~~~~~~~~~~

Number of similar (implementation,compiler) pairs: 1, namely:
ImplementationCompiler
T:opt32gcc -march=native -mtune=native -Os -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (11.4.0)

Compiler output


grain128aead.c: grain128aead.c:140:31: warning: argument 1 of type 'unsigned char[64]' with mismatched bound [-Warray-parameter=]
grain128aead.c:   140 | void auth_shift(unsigned char sr[64], unsigned char fb)
grain128aead.c:       |                 ~~~~~~~~~~~~~~^~~~~~
grain128aead.c: In file included from grain128aead.c:20:
grain128aead.c: grain128aead.h:26:31: note: previously declared as 'unsigned char[32]'
grain128aead.c:    26 | void auth_shift(unsigned char sr[32], unsigned char fb);
grain128aead.c:       |                 ~~~~~~~~~~~~~~^~~~~~
grain128aead.c: grain128aead.c: In function 'auth_shift':
grain128aead.c: grain128aead.c:145:11: warning: array subscript 63 is outside array bounds of 'unsigned char[32]' [-Warray-bounds]
grain128aead.c:   145 |         sr[63] = fb;
grain128aead.c:       |         ~~^~~~
grain128aead.c: grain128aead.c:140:31: note: while referencing 'sr'
grain128aead.c:   140 | void auth_shift(unsigned char sr[64], unsigned char fb)
grain128aead.c:       |                 ~~~~~~~~~~~~~~^~~~~~
grain128aead.c: grain128aead.c:143:23: warning: '__builtin_memmove' forming offset [32, 62] is out of the bounds [0, 32] [-Warray-bounds]
grain128aead.c:   143 |                 sr[i] = sr[i+1];
grain128aead.c:       |                 ~~~~~~^~~~~~~~~

Number of similar (implementation,compiler) pairs: 3, namely:
ImplementationCompiler
T:refgcc -march=native -mtune=native -O2 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (11.4.0)
T:refgcc -march=native -mtune=native -O3 -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (11.4.0)
T:refgcc -march=native -mtune=native -Os -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (11.4.0)

Compiler output


grain128aead.c: grain128aead.c:140:31: warning: argument 1 of type 'unsigned char[64]' with mismatched bound [-Warray-parameter=]
grain128aead.c:   140 | void auth_shift(unsigned char sr[64], unsigned char fb)
grain128aead.c:       |                 ~~~~~~~~~~~~~~^~~~~~
grain128aead.c: In file included from grain128aead.c:20:
grain128aead.c: grain128aead.h:26:31: note: previously declared as 'unsigned char[32]'
grain128aead.c:    26 | void auth_shift(unsigned char sr[32], unsigned char fb);
grain128aead.c:       |                 ~~~~~~~~~~~~~~^~~~~~

Number of similar (implementation,compiler) pairs: 1, namely:
ImplementationCompiler
T:refgcc -march=native -mtune=native -O -fwrapv -fPIC -fPIE -gdwarf-4 -Wall (11.4.0)