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_recursive | 7 | 876 | 0.008 |
| fib_iter | 8 | 899 | 0.008 |
| modules | 2 | 177 | 0.010 |
| loops | 4 | 291 | 0.013 |
| asdl_generated | 7 | 375 | 0.019 |
| parse | 25 | 747 | 0.033 |
| scoped_resource | 48 | 1,027 | 0.046 |
| files | 4 | 72 | 0.051 |
| tuple_return_value | 13 | 183 | 0.073 |
| containers | 12 | 104 | 0.112 |
| classes | 3 | 22 | 0.147 |
| length | 46 | 200 | 0.231 |
| cartesian | 78 | 328 | 0.240 |
| escape | 95 | 341 | 0.278 |
| cgi | 264 | 511 | 0.518 |
| varargs | 12 | 12 | 0.980 |
| control_flow | 212 | 108 | 1.958 |
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.7 | 0.49 |
| fib_iter | 3.7 | 7.1 | 0.52 |
| tuple_return_value | 3.7 | 7.1 | 0.52 |
| loops | 3.8 | 7.2 | 0.53 |
| asdl_generated | 3.7 | 6.9 | 0.53 |
| cartesian | 3.7 | 6.9 | 0.53 |
| cgi | 3.7 | 6.9 | 0.53 |
| escape | 3.7 | 6.9 | 0.53 |
| control_flow | 3.8 | 7.1 | 0.54 |
| scoped_resource | 3.8 | 7.1 | 0.54 |
| fib_recursive | 3.7 | 6.8 | 0.54 |
| files | 3.8 | 6.9 | 0.55 |
| modules | 3.8 | 6.9 | 0.55 |
| length | 3.9 | 6.9 | 0.57 |
| containers | 28.5 | 47.8 | 0.60 |
| varargs | 5.4 | 6.9 | 0.77 |
Lower ratios are better.
| example name | C++ | Python | C++ : Python |
| cgi | 0 | 4 | 0.000 |
| classes | 0 | 9 | 0.000 |
| fib_iter | 0 | 8 | 0.000 |
| length | 0 | 12 | 0.000 |
| loops | 0 | 8 | 0.000 |
| modules | 0 | 4 | 0.000 |
| scoped_resource | 0 | 4 | 0.000 |
| containers | 4 | 32 | 0.122 |
| fib_recursive | 4 | 12 | 0.300 |
| control_flow | 4 | 8 | 0.499 |
| parse | 4 | 8 | 0.519 |
| tuple_return_value | 7 | 8 | 0.820 |
| asdl_generated | 4 | 4 | 0.910 |
| varargs | 54 | 60 | 0.915 |
| files | 4 | 4 | 0.927 |
| cartesian | 12 | 8 | 1.474 |
| escape | 12 | 4 | 2.958 |