Measure the speedup from mycpp, and the resource usage.
Source code: oil/mycpp/examples
Lower ratios are better.
example name | C++ | Python | C++ : Python |
modules | 0 | 177 | 0.000 |
fib_iter | 4 | 895 | 0.004 |
fib_recursive | 7 | 896 | 0.008 |
loops | 4 | 296 | 0.013 |
asdl_generated | 11 | 376 | 0.029 |
parse | 25 | 756 | 0.033 |
containers | 4 | 109 | 0.035 |
scoped_resource | 39 | 1,035 | 0.038 |
tuple_return_value | 20 | 212 | 0.094 |
files | 7 | 72 | 0.103 |
classes | 3 | 17 | 0.186 |
length | 44 | 205 | 0.216 |
escape | 88 | 353 | 0.248 |
cartesian | 88 | 332 | 0.264 |
varargs | 8 | 24 | 0.347 |
cgi | 265 | 505 | 0.525 |
control_flow | 203 | 111 | 1.838 |
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.6 | 0.42 |
scoped_resource | 3.7 | 7.2 | 0.51 |
cartesian | 3.5 | 6.9 | 0.51 |
parse | 3.9 | 7.6 | 0.52 |
cgi | 3.7 | 7.1 | 0.52 |
escape | 3.7 | 7.1 | 0.52 |
asdl_generated | 3.7 | 6.9 | 0.53 |
tuple_return_value | 3.7 | 6.9 | 0.53 |
loops | 3.8 | 7.1 | 0.54 |
fib_iter | 3.8 | 6.9 | 0.55 |
files | 3.8 | 6.9 | 0.55 |
length | 3.8 | 6.9 | 0.55 |
modules | 3.8 | 6.9 | 0.55 |
fib_recursive | 3.9 | 6.9 | 0.57 |
control_flow | 3.9 | 6.8 | 0.58 |
containers | 28.6 | 48.0 | 0.60 |
varargs | 5.5 | 7.1 | 0.78 |
Lower ratios are better.
example name | C++ | Python | C++ : Python |
asdl_generated | 0 | 4 | 0.000 |
classes | 0 | 13 | 0.000 |
files | 0 | 4 | 0.000 |
length | 0 | 4 | 0.000 |
loops | 0 | 4 | 0.000 |
tuple_return_value | 0 | 8 | 0.000 |
parse | 4 | 12 | 0.348 |
modules | 2 | 4 | 0.438 |
containers | 11 | 24 | 0.472 |
fib_iter | 4 | 8 | 0.476 |
cgi | 4 | 8 | 0.498 |
fib_recursive | 4 | 4 | 0.898 |
control_flow | 4 | 4 | 0.973 |
scoped_resource | 8 | 8 | 0.973 |
cartesian | 4 | 4 | 0.996 |
varargs | 58 | 48 | 1.213 |
escape | 20 | 12 | 1.672 |