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 | 16 | 0.000 |
modules | 0 | 167 | 0.000 |
fib_iter | 8 | 899 | 0.008 |
fib_recursive | 11 | 873 | 0.013 |
loops | 4 | 295 | 0.014 |
parse | 22 | 782 | 0.029 |
asdl_generated | 11 | 381 | 0.029 |
containers | 4 | 122 | 0.033 |
scoped_resource | 39 | 1,060 | 0.037 |
tuple_return_value | 16 | 196 | 0.083 |
files | 8 | 77 | 0.100 |
length | 45 | 198 | 0.229 |
cartesian | 87 | 324 | 0.268 |
escape | 102 | 352 | 0.288 |
cgi | 270 | 513 | 0.526 |
varargs | 24 | 24 | 0.982 |
control_flow | 208 | 105 | 1.982 |
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.5 | 0.51 |
asdl_generated | 3.5 | 6.9 | 0.51 |
escape | 3.5 | 6.9 | 0.51 |
scoped_resource | 3.7 | 7.1 | 0.52 |
fib_iter | 3.7 | 6.9 | 0.53 |
fib_recursive | 3.7 | 6.9 | 0.53 |
files | 3.7 | 6.9 | 0.53 |
modules | 3.7 | 6.9 | 0.53 |
loops | 3.8 | 7.1 | 0.54 |
cartesian | 3.8 | 6.9 | 0.55 |
cgi | 3.8 | 6.9 | 0.55 |
control_flow | 3.8 | 6.9 | 0.55 |
length | 3.8 | 6.9 | 0.55 |
tuple_return_value | 3.8 | 6.9 | 0.55 |
containers | 28.6 | 47.8 | 0.60 |
varargs | 5.6 | 6.9 | 0.81 |
Lower ratios are better.
example name | C++ | Python | C++ : Python |
asdl_generated | 0 | 4 | 0.000 |
control_flow | 0 | 8 | 0.000 |
fib_iter | 0 | 4 | 0.000 |
fib_recursive | 0 | 8 | 0.000 |
length | 0 | 12 | 0.000 |
loops | 0 | 8 | 0.000 |
modules | 2 | 16 | 0.118 |
classes | 4 | 16 | 0.236 |
cartesian | 4 | 8 | 0.493 |
tuple_return_value | 4 | 8 | 0.507 |
containers | 12 | 16 | 0.750 |
varargs | 44 | 48 | 0.900 |
parse | 7 | 4 | 1.864 |
escape | 8 | 4 | 2.030 |
scoped_resource | 8 | 0 | inf |
cgi | 0 | 0 | NA |
files | 0 | 0 | NA |