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 | 892 | 0.009 |
| modules | gen | 2 | 178 | 0.011 |
| fib_recursive | gen | 11 | 871 | 0.012 |
| loops | gen | 4 | 285 | 0.013 |
| asdl_generated | gen | 11 | 368 | 0.030 |
| parse | gen | 26 | 782 | 0.033 |
| containers | gen | 4 | 112 | 0.035 |
| scoped_resource | gen | 38 | 1,035 | 0.037 |
| files | gen | 8 | 73 | 0.105 |
| tuple_return_value | gen | 20 | 192 | 0.107 |
| classes | gen | 3 | 27 | 0.122 |
| length | gen | 37 | 206 | 0.180 |
| cartesian | gen | 88 | 328 | 0.267 |
| escape | gen | 106 | 340 | 0.313 |
| gc_stack_roots | gen | 2 | 4 | 0.455 |
| cgi | gen | 269 | 510 | 0.528 |
| varargs | gen | 24 | 28 | 0.831 |
| control_flow | gen | 209 | 114 | 1.831 |
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.7 | 0.41 |
| parse | gen | 3.7 | 7.6 | 0.48 |
| asdl_generated | gen | 3.5 | 6.9 | 0.51 |
| cartesian | gen | 3.5 | 6.9 | 0.51 |
| cgi | gen | 3.7 | 7.1 | 0.52 |
| control_flow | gen | 3.7 | 7.1 | 0.52 |
| gc_stack_roots | gen | 3.5 | 6.8 | 0.52 |
| escape | gen | 3.7 | 6.9 | 0.53 |
| loops | gen | 3.8 | 7.1 | 0.54 |
| tuple_return_value | gen | 3.8 | 7.1 | 0.54 |
| fib_iter | gen | 3.8 | 6.9 | 0.55 |
| fib_recursive | gen | 3.8 | 6.9 | 0.55 |
| files | gen | 3.8 | 6.9 | 0.55 |
| modules | gen | 3.8 | 6.9 | 0.55 |
| scoped_resource | gen | 3.8 | 6.9 | 0.55 |
| length | gen | 3.9 | 6.9 | 0.57 |
| containers | gen | 28.5 | 47.7 | 0.60 |
| varargs | gen | 5.6 | 6.9 | 0.81 |
Lower ratios are better.
| example name | gen | C++ | Python | C++ : Python |
| asdl_generated | gen | 0 | 12 | 0.000 |
| cgi | gen | 0 | 8 | 0.000 |
| classes | gen | 0 | 4 | 0.000 |
| control_flow | gen | 0 | 4 | 0.000 |
| escape | gen | 0 | 8 | 0.000 |
| fib_iter | gen | 0 | 4 | 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 | 4 | 0.000 |
| tuple_return_value | gen | 0 | 4 | 0.000 |
| parse | gen | 4 | 12 | 0.308 |
| containers | gen | 12 | 24 | 0.492 |
| cartesian | gen | 4 | 8 | 0.498 |
| varargs | gen | 43 | 45 | 0.970 |
| scoped_resource | gen | 9 | 4 | 2.128 |
| length | gen | 8 | 0 | inf |