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 | 8 | 895 | 0.008 |
| loops | gen | 3 | 288 | 0.010 |
| modules | gen | 2 | 170 | 0.010 |
| fib_recursive | gen | 11 | 873 | 0.012 |
| asdl_generated | gen | 11 | 385 | 0.028 |
| parse | gen | 27 | 761 | 0.035 |
| scoped_resource | gen | 37 | 1,031 | 0.036 |
| containers | gen | 7 | 123 | 0.056 |
| tuple_return_value | gen | 11 | 192 | 0.059 |
| files | gen | 7 | 79 | 0.094 |
| classes | gen | 3 | 23 | 0.143 |
| length | gen | 40 | 196 | 0.205 |
| cartesian | gen | 82 | 329 | 0.249 |
| escape | gen | 92 | 347 | 0.263 |
| gc_stack_roots | gen | 2 | 4 | 0.438 |
| cgi | gen | 269 | 506 | 0.532 |
| varargs | gen | 21 | 36 | 0.572 |
| control_flow | gen | 160 | 111 | 1.438 |
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.3 | 10.6 | 0.41 |
| gc_stack_roots | gen | 3.4 | 7.1 | 0.48 |
| parse | gen | 3.7 | 7.6 | 0.48 |
| asdl_generated | gen | 3.4 | 6.9 | 0.49 |
| escape | gen | 3.5 | 6.9 | 0.51 |
| loops | gen | 3.7 | 7.1 | 0.52 |
| scoped_resource | gen | 3.7 | 7.1 | 0.52 |
| cartesian | gen | 3.7 | 6.9 | 0.53 |
| cgi | gen | 3.7 | 6.9 | 0.53 |
| control_flow | gen | 3.7 | 6.9 | 0.53 |
| files | gen | 3.7 | 6.9 | 0.53 |
| length | gen | 3.7 | 6.9 | 0.53 |
| modules | gen | 3.7 | 6.9 | 0.53 |
| fib_iter | gen | 3.8 | 6.9 | 0.55 |
| fib_recursive | gen | 3.8 | 6.9 | 0.55 |
| tuple_return_value | gen | 3.8 | 6.9 | 0.55 |
| containers | gen | 28.5 | 47.8 | 0.60 |
| varargs | gen | 5.5 | 6.9 | 0.79 |
Lower ratios are better.
| example name | gen | C++ | Python | C++ : Python |
| asdl_generated | gen | 0 | 12 | 0.000 |
| classes | gen | 0 | 8 | 0.000 |
| control_flow | gen | 0 | 4 | 0.000 |
| fib_iter | gen | 0 | 8 | 0.000 |
| fib_recursive | gen | 0 | 8 | 0.000 |
| files | gen | 0 | 4 | 0.000 |
| gc_stack_roots | gen | 0 | 8 | 0.000 |
| loops | gen | 0 | 12 | 0.000 |
| modules | gen | 0 | 12 | 0.000 |
| parse | gen | 0 | 12 | 0.000 |
| length | gen | 4 | 12 | 0.335 |
| containers | gen | 7 | 16 | 0.438 |
| cgi | gen | 4 | 8 | 0.500 |
| tuple_return_value | gen | 8 | 8 | 0.942 |
| scoped_resource | gen | 8 | 8 | 1.023 |
| varargs | gen | 45 | 36 | 1.259 |
| escape | gen | 16 | 8 | 1.993 |
| cartesian | gen | 4 | 0 | inf |