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 | 20 | 0.000 |
fib_recursive | 7 | 874 | 0.008 |
fib_iter | 8 | 895 | 0.008 |
modules | 2 | 181 | 0.010 |
loops | 4 | 296 | 0.012 |
asdl_generated | 11 | 376 | 0.028 |
parse | 25 | 755 | 0.033 |
scoped_resource | 43 | 1,032 | 0.042 |
containers | 8 | 119 | 0.067 |
tuple_return_value | 20 | 186 | 0.106 |
files | 8 | 65 | 0.119 |
length | 37 | 202 | 0.181 |
cartesian | 79 | 327 | 0.242 |
escape | 106 | 355 | 0.299 |
cgi | 242 | 506 | 0.478 |
varargs | 16 | 16 | 1.039 |
control_flow | 202 | 110 | 1.836 |
Lower ratios are better. We use MB (powers of 10), not MiB (powers of 2).
example name | C++ | Python | C++ : Python |
classes | 4.3 | 10.7 | 0.40 |
cgi | 3.4 | 6.9 | 0.49 |
parse | 3.8 | 7.6 | 0.50 |
cartesian | 3.5 | 6.9 | 0.51 |
asdl_generated | 3.7 | 6.9 | 0.53 |
tuple_return_value | 3.7 | 6.9 | 0.53 |
loops | 3.8 | 7.1 | 0.54 |
escape | 3.8 | 6.9 | 0.55 |
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 |
scoped_resource | 3.8 | 6.9 | 0.55 |
control_flow | 3.9 | 7.1 | 0.56 |
fib_recursive | 3.9 | 6.9 | 0.57 |
containers | 28.7 | 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 |
fib_iter | 0 | 4 | 0.000 |
files | 0 | 11 | 0.000 |
modules | 0 | 4 | 0.000 |
tuple_return_value | 0 | 8 | 0.000 |
classes | 3 | 12 | 0.273 |
containers | 8 | 20 | 0.400 |
fib_recursive | 4 | 8 | 0.449 |
scoped_resource | 4 | 8 | 0.496 |
parse | 4 | 8 | 0.522 |
varargs | 49 | 55 | 0.890 |
cgi | 8 | 8 | 1.012 |
length | 8 | 8 | 1.024 |
control_flow | 8 | 4 | 1.944 |
cartesian | 12 | 4 | 3.134 |
escape | 0 | 0 | NA |
loops | 0 | 0 | NA |