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 | 914 | 0.008 |
| modules | gen | 2 | 182 | 0.010 |
| fib_recursive | gen | 11 | 1,072 | 0.010 |
| loops | gen | 4 | 305 | 0.012 |
| asdl_generated | gen | 7 | 370 | 0.020 |
| parse | gen | 29 | 776 | 0.038 |
| scoped_resource | gen | 47 | 1,030 | 0.046 |
| files | gen | 7 | 75 | 0.098 |
| containers | gen | 12 | 114 | 0.102 |
| tuple_return_value | gen | 20 | 185 | 0.109 |
| classes | gen | 3 | 17 | 0.188 |
| cartesian | gen | 75 | 348 | 0.214 |
| length | gen | 44 | 201 | 0.220 |
| escape | gen | 103 | 350 | 0.293 |
| cgi | gen | 265 | 505 | 0.524 |
| varargs | gen | 27 | 20 | 1.368 |
| control_flow | gen | 208 | 107 | 1.942 |
| gc_stack_roots | gen | 2 | 0 | inf |
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.9 | 0.41 |
| parse | gen | 3.8 | 7.5 | 0.51 |
| cgi | gen | 3.5 | 6.9 | 0.51 |
| gc_stack_roots | gen | 3.5 | 6.9 | 0.51 |
| cartesian | gen | 3.7 | 7.1 | 0.52 |
| fib_recursive | gen | 3.7 | 7.1 | 0.52 |
| asdl_generated | gen | 3.7 | 6.9 | 0.53 |
| escape | gen | 3.7 | 6.9 | 0.53 |
| length | gen | 3.7 | 6.9 | 0.53 |
| scoped_resource | gen | 3.7 | 6.9 | 0.53 |
| loops | gen | 3.8 | 7.1 | 0.54 |
| fib_iter | gen | 3.8 | 6.9 | 0.55 |
| files | gen | 3.8 | 6.9 | 0.55 |
| modules | gen | 3.8 | 6.8 | 0.56 |
| tuple_return_value | gen | 3.8 | 6.8 | 0.56 |
| control_flow | gen | 3.9 | 6.8 | 0.58 |
| containers | gen | 28.7 | 47.8 | 0.60 |
| varargs | gen | 5.6 | 6.9 | 0.81 |
Lower ratios are better.
| example name | gen | C++ | Python | C++ : Python |
| classes | gen | 0 | 13 | 0.000 |
| control_flow | gen | 0 | 4 | 0.000 |
| fib_iter | gen | 0 | 4 | 0.000 |
| fib_recursive | gen | 0 | 4 | 0.000 |
| gc_stack_roots | gen | 0 | 12 | 0.000 |
| length | gen | 0 | 12 | 0.000 |
| modules | gen | 0 | 8 | 0.000 |
| parse | gen | 0 | 8 | 0.000 |
| scoped_resource | gen | 0 | 4 | 0.000 |
| tuple_return_value | gen | 0 | 8 | 0.000 |
| containers | gen | 4 | 20 | 0.196 |
| asdl_generated | gen | 4 | 12 | 0.303 |
| varargs | gen | 39 | 52 | 0.751 |
| escape | gen | 4 | 4 | 0.981 |
| cgi | gen | 4 | 4 | 1.000 |
| cartesian | gen | 16 | 0 | inf |
| files | gen | 0 | 0 | NA |
| loops | gen | 0 | 0 | NA |