Measure the speedup from mycpp, and the resource usage.
Source code: oil/mycpp/examples
Lower ratios are better.
| example name | gen | C++ | Python | C++ : Python |
| fib_iter | gen | 4 | 891 | 0.004 |
| modules | gen | 2 | 178 | 0.010 |
| fib_recursive | gen | 11 | 901 | 0.012 |
| loops | gen | 4 | 302 | 0.012 |
| asdl_generated | gen | 11 | 402 | 0.027 |
| containers | gen | 4 | 123 | 0.031 |
| parse | gen | 25 | 762 | 0.033 |
| scoped_resource | gen | 43 | 1,024 | 0.042 |
| tuple_return_value | gen | 20 | 186 | 0.107 |
| files | gen | 8 | 67 | 0.115 |
| classes | gen | 3 | 23 | 0.141 |
| length | gen | 37 | 220 | 0.170 |
| cartesian | gen | 79 | 327 | 0.240 |
| escape | gen | 92 | 360 | 0.256 |
| gc_stack_roots | gen | 2 | 4 | 0.436 |
| cgi | gen | 265 | 514 | 0.515 |
| control_flow | gen | 214 | 106 | 2.017 |
| varargs | gen | 29 | 12 | 2.407 |
Lower ratios are better. We use MB (powers of 10), not MiB (powers of 2).
| example name | gen | C++ | Python | C++ : Python |
| classes | gen | 4.5 | 10.6 | 0.42 |
| parse | gen | 3.8 | 7.5 | 0.51 |
| cartesian | gen | 3.5 | 6.9 | 0.51 |
| modules | gen | 3.5 | 6.9 | 0.51 |
| gc_stack_roots | gen | 3.7 | 7.1 | 0.52 |
| scoped_resource | gen | 3.7 | 7.1 | 0.52 |
| tuple_return_value | gen | 3.7 | 7.1 | 0.52 |
| asdl_generated | gen | 3.7 | 6.9 | 0.53 |
| escape | gen | 3.7 | 6.9 | 0.53 |
| fib_iter | gen | 3.7 | 6.9 | 0.53 |
| fib_recursive | gen | 3.8 | 7.1 | 0.54 |
| loops | gen | 3.8 | 7.1 | 0.54 |
| cgi | gen | 3.8 | 6.9 | 0.55 |
| control_flow | gen | 3.8 | 6.9 | 0.55 |
| files | gen | 3.8 | 6.9 | 0.55 |
| length | gen | 3.8 | 6.9 | 0.55 |
| containers | gen | 28.6 | 47.8 | 0.60 |
| varargs | gen | 5.4 | 6.9 | 0.77 |
Lower ratios are better.
| example name | gen | C++ | Python | C++ : Python |
| asdl_generated | gen | 0 | 8 | 0.000 |
| classes | gen | 0 | 8 | 0.000 |
| control_flow | gen | 0 | 8 | 0.000 |
| fib_recursive | gen | 0 | 12 | 0.000 |
| files | gen | 0 | 8 | 0.000 |
| gc_stack_roots | gen | 0 | 8 | 0.000 |
| loops | gen | 0 | 8 | 0.000 |
| modules | gen | 0 | 8 | 0.000 |
| tuple_return_value | gen | 0 | 8 | 0.000 |
| scoped_resource | gen | 4 | 20 | 0.198 |
| cgi | gen | 4 | 8 | 0.496 |
| parse | gen | 4 | 8 | 0.523 |
| varargs | gen | 37 | 60 | 0.619 |
| length | gen | 7 | 8 | 0.933 |
| fib_iter | gen | 4 | 4 | 0.954 |
| containers | gen | 12 | 12 | 0.966 |
| cartesian | gen | 12 | 8 | 1.477 |
| escape | gen | 12 | 0 | inf |