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 | 19 | 0.000 |
fib_iter | 8 | 894 | 0.008 |
modules | 2 | 185 | 0.010 |
fib_recursive | 11 | 963 | 0.011 |
loops | 4 | 286 | 0.013 |
asdl_generated | 11 | 380 | 0.028 |
scoped_resource | 40 | 1,028 | 0.039 |
parse | 30 | 778 | 0.039 |
files | 4 | 73 | 0.051 |
containers | 8 | 132 | 0.059 |
tuple_return_value | 20 | 188 | 0.108 |
length | 45 | 209 | 0.216 |
cartesian | 79 | 328 | 0.241 |
escape | 97 | 370 | 0.261 |
cgi | 257 | 508 | 0.506 |
varargs | 16 | 24 | 0.655 |
control_flow | 203 | 103 | 1.972 |
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 |
asdl_generated | 3.5 | 6.9 | 0.51 |
cartesian | 3.5 | 6.9 | 0.51 |
parse | 3.9 | 7.5 | 0.53 |
cgi | 3.7 | 6.9 | 0.53 |
control_flow | 3.7 | 6.9 | 0.53 |
escape | 3.7 | 6.9 | 0.53 |
fib_iter | 3.7 | 6.9 | 0.53 |
modules | 3.7 | 6.9 | 0.53 |
scoped_resource | 3.7 | 6.9 | 0.53 |
tuple_return_value | 3.7 | 6.9 | 0.53 |
length | 3.8 | 7.1 | 0.54 |
loops | 3.8 | 7.1 | 0.54 |
fib_recursive | 3.7 | 6.8 | 0.54 |
files | 3.8 | 6.8 | 0.56 |
containers | 28.6 | 48.0 | 0.60 |
varargs | 5.5 | 6.9 | 0.79 |
Lower ratios are better.
example name | C++ | Python | C++ : Python |
asdl_generated | 0 | 8 | 0.000 |
fib_iter | 0 | 8 | 0.000 |
fib_recursive | 0 | 8 | 0.000 |
loops | 0 | 12 | 0.000 |
modules | 0 | 8 | 0.000 |
parse | 0 | 4 | 0.000 |
tuple_return_value | 0 | 4 | 0.000 |
classes | 3 | 11 | 0.283 |
containers | 8 | 24 | 0.324 |
control_flow | 4 | 12 | 0.335 |
files | 4 | 4 | 0.926 |
cgi | 12 | 12 | 0.988 |
scoped_resource | 8 | 8 | 0.991 |
varargs | 51 | 48 | 1.064 |
cartesian | 12 | 4 | 2.959 |
escape | 12 | 0 | inf |
length | 0 | 0 | NA |