-
Notifications
You must be signed in to change notification settings - Fork 55
Description
Using benchmarks from https://github.com/rv8-io/rv8-bench/ I see the current dynamic instruction counts (note: this isn't a perfect proxy for performance, but reasonable for initial comparisons):
Benchmark aes with -march=rv32im and -O3
gcc instret: 283330319
clang instret: 271796365
clang/gcc: 95.00%
Benchmark dhrystone with -march=rv32im and -O3
gcc instret: 274275911
clang instret: 336272568
clang/gcc: 122.00%
Benchmark norx with -march=rv32im and -O3
gcc instret: 129801139
clang instret: 134429519
clang/gcc: 103.00%
Benchmark qsort with -march=rv32im and -O3
gcc instret: 814554722
clang instret: 692674566
clang/gcc: 85.00%
Benchmark sha512 with -march=rv32im and -O3
gcc instret: 227057803
clang instret: 274505822
clang/gcc: 120.00%
clang/gcc < 100% means there are fewer dynamic instructions for the clang-generated binary, and > 100% means fewer dynamic instructions for the gcc-generated binary.
Taken with the current version of this clang+llvm patchset and a recent gcc 8.0.0 build. We did better than gcc 7.1.1 for dhrystone, but gcc has since improved.