Implementation notes: riscv64, riscvunleashed000, crypto_hash/echosp256

Computer: riscvunleashed000
Microarchitecture: riscv64; U54 (sifive,u54-mc)
Architecture: riscv64
CPU ID: unknown CPU ID
SUPERCOP version: 20240107
Operation: crypto_hash
Primitive: echosp256
TimeObject sizeTest sizeImplementationCompilerBenchmark dateSUPERCOP version
18003017314 0 023845 768 729T:generic/opt64clang_-march=rv64imafdc_-mtune=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
18028919484 0 028093 776 736T:generic/opt64clang_-mcpu=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
18029919484 0 028093 776 736T:generic/opt64clang_-march=rv64imafdc_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
18040619300 0 027497 776 736T:generic/opt64clang_-march=rv64imafdc_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
18041919300 0 027497 776 736T:generic/opt64clang_-march=rv64imafdc_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
21177618571 0 027204 792 744T:generic/opt32clang_-march=rv64imafdc_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
21179818571 0 027204 792 744T:generic/opt32clang_-mcpu=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
21183418511 0 026752 792 744T:generic/opt32clang_-march=rv64imafdc_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
21183818511 0 026752 792 744T:generic/opt32clang_-march=rv64imafdc_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
21398616891 0 023420 776 737T:generic/opt32clang_-march=rv64imafdc_-mtune=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
21649819408 0 126104 776 728T:generic/opt64gcc_-mcpu=sifive-u54_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
22312219176 0 125412 760 728T:generic/opt64gcc_-mcpu=sifive-u54_-Os_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
22830022002 0 030567 776 744T:powerpc/pp32cv2clang_-mcpu=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
22834722002 0 030567 776 744T:powerpc/pp32cv2clang_-march=rv64imafdc_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
22836021956 0 030105 776 744T:powerpc/pp32cv2clang_-march=rv64imafdc_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
22837321956 0 030105 776 744T:powerpc/pp32cv2clang_-march=rv64imafdc_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
24482719564 0 1625935 784 744T:generic/opt32gcc_-mcpu=sifive-u54_-Os_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
25520520396 0 026875 768 737T:powerpc/pp32cv2clang_-march=rv64imafdc_-mtune=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
25651219800 0 1626619 800 744T:generic/opt32gcc_-mcpu=sifive-u54_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
28835824042 0 130834 776 728T:generic/opt64gcc_-mcpu=sifive-u54_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
28875134730 0 143146 776 728T:generic/opt64gcc_-mcpu=sifive-u54_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
29414125918 0 1632161 768 744T:powerpc/pp32cv2gcc_-mcpu=sifive-u54_-Os_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
31061525614 0 1632305 784 744T:powerpc/pp32cv2gcc_-mcpu=sifive-u54_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
31116917510 0 026079 776 744T:powerpc/pp32cv1clang_-march=rv64imafdc_-mtune=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
31117617510 0 026079 776 744T:powerpc/pp32cv1clang_-mcpu=native_-O3_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
31142217480 0 025629 776 744T:powerpc/pp32cv1clang_-march=rv64imafdc_-mtune=native_-O_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
31143717480 0 025629 776 744T:powerpc/pp32cv1clang_-march=rv64imafdc_-mtune=native_-O2_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
33835916306 0 022785 768 737T:powerpc/pp32cv1clang_-march=rv64imafdc_-mtune=native_-Os_-fomit-frame-pointer_-fwrapv_-Qunused-arguments_-fPIC_-fPIE2024011220231222
35014631942 0 1640507 800 744T:generic/opt32gcc_-mcpu=sifive-u54_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
35317727288 0 1634225 800 744T:generic/opt32gcc_-mcpu=sifive-u54_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
39377336464 0 1644909 784 744T:powerpc/pp32cv2gcc_-mcpu=sifive-u54_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
40052833198 0 1640011 784 744T:powerpc/pp32cv2gcc_-mcpu=sifive-u54_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
45815817430 0 1624243 784 744T:powerpc/pp32cv1gcc_-mcpu=sifive-u54_-O2_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
48436016764 0 1623455 784 744T:powerpc/pp32cv1gcc_-mcpu=sifive-u54_-O_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
49402520418 0 1628863 784 744T:powerpc/pp32cv1gcc_-mcpu=sifive-u54_-O3_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222
50725516368 0 1622611 768 744T:powerpc/pp32cv1gcc_-mcpu=sifive-u54_-Os_-fomit-frame-pointer_-fwrapv_-fPIC_-fPIE2024011220231222

Compiler output

Implementation: T:generic/opt32
Security model: timingleaks
Compiler: clang -march=rv64imafdc -mtune=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
echo32.c: echo32.c:37:4: warning: implicitly declaring library function 'printf' with type 'int (const char *, ...)' [-Wimplicit-function-declaration]
echo32.c: printf ("row %d,col %d :",i,j);
echo32.c: ^
echo32.c: echo32.c:37:4: note: include the header <stdio.h> or explicitly provide a declaration for 'printf'
echo32.c: 1 warning generated.

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

Compiler output

Implementation: T:generic/opt32
Security model: timingleaks
Compiler: gcc -mcpu=sifive-u54 -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE
echo32.c: echo32.c: In function 'PrintState':
echo32.c: echo32.c:37:25: warning: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
echo32.c: 37 | printf ("row %d,col %d :",i,j);
echo32.c: | ^~~~~~
echo32.c: echo32.c:12:1: note: include '<stdio.h>' or provide a declaration of 'printf'
echo32.c: 11 | #include "api.h"
echo32.c: +++ |+#include <stdio.h>
echo32.c: 12 |
echo32.c: echo32.c:37:25: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
echo32.c: 37 | printf ("row %d,col %d :",i,j);
echo32.c: | ^~~~~~
echo32.c: echo32.c:37:25: note: include '<stdio.h>' or provide a declaration of 'printf'
echo32.c: echo32.c:47:9: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
echo32.c: 47 | printf("-----------------------------------\n");
echo32.c: | ^~~~~~
echo32.c: echo32.c:47:9: note: include '<stdio.h>' or provide a declaration of 'printf'

Number of similar (compiler,implementation) pairs: 4, namely:
CompilerImplementations
gcc -mcpu=sifive-u54 -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE T:generic/opt32
gcc -mcpu=sifive-u54 -O3 -fomit-frame-pointer -fwrapv -fPIC -fPIE T:generic/opt32
gcc -mcpu=sifive-u54 -O -fomit-frame-pointer -fwrapv -fPIC -fPIE T:generic/opt32
gcc -mcpu=sifive-u54 -Os -fomit-frame-pointer -fwrapv -fPIC -fPIE T:generic/opt32

Compiler output

Implementation: T:generic/opt64
Security model: timingleaks
Compiler: clang -march=rv64imafdc -mtune=native -O2 -fomit-frame-pointer -fwrapv -Qunused-arguments -fPIC -fPIE
echo64.c: echo64.c:555:29: warning: passing 'const unsigned char *' to parameter of type 'BitSequence *' (aka 'unsigned char *') discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
echo64.c: if (Hash(CRYPTO_BYTES * 8,in,inlen * 8,out) == SUCCESS) return 0;
echo64.c: ^~
echo64.c: echo64.c:542:46: note: passing argument to parameter 'data' here
echo64.c: HashReturn Hash(int hashbitlen, BitSequence *data, DataLength databitlen, BitSequence *hashval)
echo64.c: ^
echo64.c: 1 warning generated.

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

Compiler output

Implementation: T:generic/opt64
Security model: timingleaks
Compiler: gcc -mcpu=sifive-u54 -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE
echo64.c: echo64.c: In function 'crypto_hash_echosp256_generic_opt64_timingleaks':
echo64.c: echo64.c:555:29: warning: passing argument 2 of 'Hash' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
echo64.c: 555 | if (Hash(CRYPTO_BYTES * 8,in,inlen * 8,out) == SUCCESS) return 0;
echo64.c: | ^~
echo64.c: echo64.c:542:46: note: expected 'BitSequence *' {aka 'unsigned char *'} but argument is of type 'const unsigned char *'
echo64.c: 542 | HashReturn Hash(int hashbitlen, BitSequence *data, DataLength databitlen, BitSequence *hashval)
echo64.c: | ~~~~~~~~~~~~~^~~~

Number of similar (compiler,implementation) pairs: 4, namely:
CompilerImplementations
gcc -mcpu=sifive-u54 -O2 -fomit-frame-pointer -fwrapv -fPIC -fPIE T:generic/opt64
gcc -mcpu=sifive-u54 -O3 -fomit-frame-pointer -fwrapv -fPIC -fPIE T:generic/opt64
gcc -mcpu=sifive-u54 -O -fomit-frame-pointer -fwrapv -fPIC -fPIE T:generic/opt64
gcc -mcpu=sifive-u54 -Os -fomit-frame-pointer -fwrapv -fPIC -fPIE T:generic/opt64