Performance Evaluation of C, C++, MicroPython, Rust and TinyGo on ESP32
mdpi.com
mdpi.com
Unfortunately there are no summary results, so I calculated them myself; the geomean of the factor "language x / C" for the time averages are:
- 1.2 for Go,
- 1.4 for Rust and
- 401.7 for Python.
According to Table 5 there are only C results, no C++ results. It's unfortunate that the authors put C and C++ on par, since the results are likely not the same and C++ is still rarely used on microcontroller embedded systems. I also do not find a clear statement in the paper whether the benchmarks were only run on one or distributed on both cores.
Also the conclusion is somewhat peculiar; it is to be expected that a single language might perform better or worse than another when just comparing single microbenchmarks; on its own, this says nothing at all. Only by comparing a set of suitable benchmarks that cover the all relevant challenges for a compiler and/or runtime system can one make a reasonably reliable statement about the performance difference.
But the authors' point seems to have been to show that Go and Rust (presumably Rust in particular) are suitable substitutes for C in terms of performance, but the data does not support this conclusion. That's probably why they left out the overall results, because they show that Rust is 40% slower than C, and surprisingly even slower than Go.