Measure the speedup from mycpp, and the resource usage.
Source code: oil/mycpp/examples
Lower ratios are better.
example name | C++ | Python | C++ : Python |
fib_iter | 4 | 883 | 0.004 |
modules | 2 | 174 | 0.010 |
fib_recursive | 11 | 899 | 0.012 |
loops | 4 | 297 | 0.012 |
asdl_generated | 11 | 384 | 0.029 |
parse | 25 | 818 | 0.031 |
scoped_resource | 47 | 1,035 | 0.045 |
containers | 8 | 102 | 0.078 |
tuple_return_value | 16 | 182 | 0.089 |
files | 8 | 77 | 0.105 |
classes | 3 | 20 | 0.165 |
length | 45 | 207 | 0.216 |
cartesian | 90 | 329 | 0.274 |
escape | 100 | 357 | 0.279 |
cgi | 258 | 514 | 0.501 |
varargs | 12 | 12 | 0.969 |
control_flow | 201 | 117 | 1.724 |
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.8 | 0.41 |
parse | 3.7 | 7.6 | 0.48 |
scoped_resource | 3.5 | 7.1 | 0.50 |
fib_iter | 3.7 | 7.1 | 0.52 |
files | 3.7 | 7.1 | 0.52 |
asdl_generated | 3.7 | 6.9 | 0.53 |
cartesian | 3.7 | 6.9 | 0.53 |
escape | 3.7 | 6.9 | 0.53 |
length | 3.8 | 7.1 | 0.54 |
control_flow | 3.8 | 6.9 | 0.55 |
fib_recursive | 3.8 | 6.9 | 0.55 |
modules | 3.8 | 6.9 | 0.55 |
tuple_return_value | 3.8 | 6.9 | 0.55 |
loops | 3.9 | 7.1 | 0.56 |
cgi | 3.8 | 6.8 | 0.56 |
containers | 28.4 | 47.8 | 0.59 |
varargs | 5.5 | 6.9 | 0.79 |
Lower ratios are better.
example name | C++ | Python | C++ : Python |
cartesian | 0 | 12 | 0.000 |
classes | 0 | 12 | 0.000 |
fib_recursive | 0 | 8 | 0.000 |
length | 0 | 4 | 0.000 |
loops | 0 | 4 | 0.000 |
modules | 0 | 8 | 0.000 |
scoped_resource | 0 | 8 | 0.000 |
containers | 8 | 35 | 0.226 |
tuple_return_value | 4 | 12 | 0.339 |
varargs | 55 | 60 | 0.904 |
fib_iter | 4 | 4 | 0.961 |
parse | 4 | 4 | 1.043 |
cgi | 8 | 4 | 1.975 |
control_flow | 8 | 0 | inf |
escape | 8 | 0 | inf |
asdl_generated | 0 | 0 | NA |
files | 0 | 0 | NA |