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_iter | 8 | 895 | 0.009 |
| modules | 2 | 174 | 0.010 |
| fib_recursive | 11 | 980 | 0.011 |
| loops | 4 | 314 | 0.012 |
| asdl_generated | 7 | 384 | 0.019 |
| parse | 26 | 800 | 0.032 |
| scoped_resource | 43 | 1,024 | 0.042 |
| containers | 5 | 106 | 0.048 |
| tuple_return_value | 20 | 191 | 0.104 |
| files | 8 | 68 | 0.112 |
| classes | 3 | 23 | 0.146 |
| length | 44 | 198 | 0.222 |
| cartesian | 86 | 320 | 0.270 |
| escape | 99 | 366 | 0.271 |
| cgi | 266 | 511 | 0.520 |
| varargs | 20 | 20 | 1.013 |
| control_flow | 210 | 107 | 1.956 |
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 |
| cartesian | 3.7 | 6.9 | 0.53 |
| cgi | 3.7 | 6.9 | 0.53 |
| length | 3.7 | 6.9 | 0.53 |
| scoped_resource | 3.7 | 6.9 | 0.53 |
| fib_iter | 3.8 | 6.9 | 0.55 |
| fib_recursive | 3.8 | 6.9 | 0.55 |
| loops | 3.8 | 6.9 | 0.55 |
| modules | 3.8 | 6.9 | 0.55 |
| tuple_return_value | 3.8 | 6.9 | 0.55 |
| files | 3.8 | 6.8 | 0.56 |
| control_flow | 3.9 | 6.9 | 0.57 |
| containers | 28.5 | 48.0 | 0.59 |
| varargs | 5.6 | 6.9 | 0.81 |
Lower ratios are better.
| example name | C++ | Python | C++ : Python |
| cgi | 0 | 4 | 0.000 |
| classes | 0 | 8 | 0.000 |
| control_flow | 0 | 8 | 0.000 |
| fib_iter | 0 | 4 | 0.000 |
| fib_recursive | 0 | 12 | 0.000 |
| files | 0 | 8 | 0.000 |
| length | 0 | 12 | 0.000 |
| loops | 0 | 4 | 0.000 |
| modules | 0 | 8 | 0.000 |
| tuple_return_value | 0 | 4 | 0.000 |
| parse | 4 | 12 | 0.306 |
| containers | 10 | 31 | 0.325 |
| cartesian | 4 | 8 | 0.515 |
| varargs | 45 | 52 | 0.857 |
| asdl_generated | 4 | 4 | 0.906 |
| escape | 8 | 8 | 0.998 |
| scoped_resource | 4 | 0 | inf |