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 | 24 | 0.000 |
fib_recursive | 7 | 954 | 0.008 |
fib_iter | 8 | 890 | 0.009 |
modules | 2 | 188 | 0.011 |
loops | 4 | 296 | 0.013 |
asdl_generated | 7 | 366 | 0.020 |
parse | 30 | 762 | 0.039 |
scoped_resource | 44 | 1,031 | 0.042 |
containers | 12 | 109 | 0.107 |
files | 8 | 70 | 0.110 |
tuple_return_value | 20 | 183 | 0.110 |
length | 41 | 200 | 0.203 |
cartesian | 84 | 328 | 0.256 |
escape | 99 | 347 | 0.286 |
cgi | 249 | 503 | 0.495 |
control_flow | 201 | 106 | 1.894 |
varargs | 28 | 8 | 3.631 |
Lower ratios are better. We use MB (powers of 10), not MiB (powers of 2).
example name | C++ | Python | C++ : Python |
classes | 4.6 | 10.8 | 0.43 |
parse | 3.8 | 7.6 | 0.50 |
loops | 3.7 | 7.2 | 0.51 |
cartesian | 3.7 | 7.1 | 0.52 |
escape | 3.7 | 7.1 | 0.52 |
asdl_generated | 3.7 | 6.9 | 0.53 |
cgi | 3.7 | 6.9 | 0.53 |
scoped_resource | 3.7 | 6.9 | 0.53 |
tuple_return_value | 3.7 | 6.9 | 0.53 |
fib_iter | 3.7 | 6.8 | 0.54 |
length | 3.8 | 6.9 | 0.55 |
modules | 3.9 | 7.1 | 0.56 |
files | 3.8 | 6.8 | 0.56 |
control_flow | 3.9 | 6.9 | 0.57 |
fib_recursive | 3.9 | 6.9 | 0.57 |
containers | 28.7 | 48.0 | 0.60 |
varargs | 5.5 | 6.9 | 0.79 |
Lower ratios are better.
example name | C++ | Python | C++ : Python |
fib_iter | 0 | 4 | 0.000 |
files | 0 | 8 | 0.000 |
loops | 0 | 8 | 0.000 |
modules | 0 | 8 | 0.000 |
parse | 0 | 8 | 0.000 |
tuple_return_value | 0 | 8 | 0.000 |
containers | 4 | 28 | 0.137 |
asdl_generated | 4 | 12 | 0.296 |
cgi | 4 | 12 | 0.335 |
length | 4 | 12 | 0.339 |
classes | 3 | 8 | 0.418 |
fib_recursive | 4 | 8 | 0.454 |
scoped_resource | 4 | 8 | 0.498 |
varargs | 39 | 64 | 0.610 |
control_flow | 8 | 8 | 1.003 |
escape | 8 | 4 | 1.991 |
cartesian | 8 | 4 | 1.997 |