Measure the speedup from mycpp, and the resource usage.
Source code: oil/mycpp/examples
Lower ratios are better.
example name | C++ | Python | C++ : Python |
loops | 0 | 287 | 0.000 |
modules | 0 | 347 | 0.000 |
fib_recursive | 7 | 891 | 0.008 |
fib_iter | 7 | 878 | 0.008 |
asdl_generated | 11 | 369 | 0.029 |
parse | 24 | 785 | 0.031 |
containers | 4 | 106 | 0.036 |
scoped_resource | 43 | 1,013 | 0.043 |
files | 4 | 72 | 0.051 |
tuple_return_value | 17 | 179 | 0.095 |
classes | 3 | 17 | 0.181 |
length | 41 | 191 | 0.213 |
cartesian | 83 | 326 | 0.254 |
escape | 96 | 347 | 0.277 |
cgi | 254 | 514 | 0.494 |
control_flow | 209 | 101 | 2.061 |
varargs | 16 | 4 | 3.902 |
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.7 | 0.49 |
fib_iter | 3.5 | 7.1 | 0.50 |
cartesian | 3.5 | 6.9 | 0.51 |
escape | 3.5 | 6.9 | 0.51 |
loops | 3.7 | 7.1 | 0.52 |
modules | 3.7 | 7.1 | 0.52 |
asdl_generated | 3.7 | 6.9 | 0.53 |
cgi | 3.7 | 6.9 | 0.53 |
length | 3.7 | 6.9 | 0.53 |
tuple_return_value | 3.7 | 6.9 | 0.53 |
fib_recursive | 3.8 | 7.1 | 0.54 |
scoped_resource | 3.8 | 7.1 | 0.54 |
control_flow | 3.8 | 6.9 | 0.55 |
files | 3.8 | 6.8 | 0.56 |
containers | 28.7 | 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 |
cgi | 0 | 8 | 0.000 |
classes | 0 | 13 | 0.000 |
control_flow | 0 | 12 | 0.000 |
fib_iter | 0 | 8 | 0.000 |
parse | 4 | 12 | 0.339 |
length | 4 | 12 | 0.341 |
containers | 11 | 28 | 0.396 |
tuple_return_value | 3 | 8 | 0.429 |
modules | 2 | 4 | 0.440 |
loops | 4 | 8 | 0.462 |
scoped_resource | 4 | 8 | 0.539 |
varargs | 50 | 68 | 0.746 |
files | 4 | 4 | 0.925 |
cartesian | 8 | 8 | 0.979 |
escape | 12 | 4 | 3.010 |
fib_recursive | 4 | 0 | inf |