Measure the speedup from mycpp, and the resource usage.
Source code: oil/mycpp/examples
Lower ratios are better.
example name | C++ | Python | C++ : Python |
classes | 0 | 31 | 0.000 |
containers | 0 | 120 | 0.000 |
loops | 0 | 295 | 0.000 |
fib_recursive | 7 | 890 | 0.008 |
fib_iter | 8 | 883 | 0.009 |
modules | 2 | 173 | 0.011 |
asdl_generated | 11 | 371 | 0.029 |
parse | 26 | 757 | 0.034 |
scoped_resource | 44 | 1,034 | 0.042 |
tuple_return_value | 12 | 181 | 0.067 |
files | 7 | 68 | 0.108 |
length | 44 | 198 | 0.224 |
cartesian | 90 | 345 | 0.262 |
escape | 90 | 338 | 0.268 |
cgi | 265 | 505 | 0.525 |
control_flow | 204 | 105 | 1.937 |
varargs | 17 | 8 | 2.100 |
Lower ratios are better. We use MB (powers of 10), not MiB (powers of 2).
example name | C++ | Python | C++ : Python |
classes | 4.5 | 10.7 | 0.41 |
parse | 3.8 | 7.6 | 0.50 |
cartesian | 3.5 | 6.9 | 0.51 |
fib_iter | 3.5 | 6.9 | 0.51 |
scoped_resource | 3.7 | 7.1 | 0.52 |
asdl_generated | 3.5 | 6.8 | 0.52 |
cgi | 3.7 | 6.9 | 0.53 |
escape | 3.7 | 6.9 | 0.53 |
fib_recursive | 3.7 | 6.9 | 0.53 |
files | 3.7 | 6.9 | 0.53 |
length | 3.7 | 6.9 | 0.53 |
modules | 3.7 | 6.9 | 0.53 |
tuple_return_value | 3.7 | 6.9 | 0.53 |
control_flow | 3.8 | 7.1 | 0.54 |
loops | 3.8 | 7.1 | 0.54 |
containers | 28.5 | 47.8 | 0.60 |
varargs | 5.5 | 6.9 | 0.79 |
Lower ratios are better.
example name | C++ | Python | C++ : Python |
asdl_generated | 0 | 12 | 0.000 |
cartesian | 0 | 4 | 0.000 |
fib_iter | 0 | 8 | 0.000 |
files | 0 | 8 | 0.000 |
length | 0 | 12 | 0.000 |
modules | 0 | 8 | 0.000 |
cgi | 4 | 12 | 0.334 |
fib_recursive | 4 | 8 | 0.448 |
parse | 4 | 8 | 0.462 |
scoped_resource | 4 | 8 | 0.499 |
control_flow | 4 | 8 | 0.513 |
tuple_return_value | 8 | 12 | 0.681 |
varargs | 50 | 63 | 0.788 |
loops | 4 | 4 | 0.899 |
containers | 16 | 16 | 0.975 |
escape | 16 | 16 | 0.989 |
classes | 3 | 0 | inf |