2 ms·
The first example (the sum in C) is certainly optimized away. I'd be careful drawing too many conclusions about these examples because the code is dodgy (doesn'
by alkonaut 10y ago
The first example (the sum in C) is certainly optimized away. I'd be careful drawing too many conclusions about these examples because the code is dodgy (doesn't use sums etc), the optimizations are probably incorrect (reasonable compiler flags were added after the results were generated).
You could think of them as thought experiments e.g. "how many ADD's can we make on a single thread on an average PC?" rather than "What would the runtime of this C program be on an average PC?". Since the results were generated without optimizations, at least for the C programs, there is not much point in talking about runtime.