Measure the speedup from mycpp, and the resource usage.
Source code: oil/mycpp/examples
Lower ratios are better.
| example name | C++ | Python | C++ : Python |
| loops | 0 | 289 | 0.000 |
| fib_iter | 4 | 912 | 0.004 |
| modules | 2 | 174 | 0.010 |
| fib_recursive | 11 | 883 | 0.012 |
| asdl_generated | 11 | 375 | 0.029 |
| parse | 25 | 781 | 0.032 |
| containers | 4 | 107 | 0.036 |
| scoped_resource | 40 | 1,033 | 0.038 |
| tuple_return_value | 10 | 189 | 0.054 |
| files | 7 | 71 | 0.104 |
| length | 36 | 207 | 0.176 |
| classes | 3 | 15 | 0.209 |
| cartesian | 82 | 332 | 0.248 |
| escape | 90 | 352 | 0.257 |
| cgi | 253 | 519 | 0.488 |
| varargs | 16 | 20 | 0.779 |
| control_flow | 207 | 110 | 1.884 |
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.8 | 0.41 |
| parse | 3.8 | 7.5 | 0.51 |
| scoped_resource | 3.7 | 7.2 | 0.51 |
| asdl_generated | 3.5 | 6.9 | 0.51 |
| cartesian | 3.5 | 6.9 | 0.51 |
| fib_recursive | 3.7 | 7.1 | 0.52 |
| length | 3.7 | 7.1 | 0.52 |
| cgi | 3.5 | 6.8 | 0.52 |
| control_flow | 3.8 | 7.1 | 0.54 |
| fib_iter | 3.8 | 7.1 | 0.54 |
| modules | 3.8 | 7.1 | 0.54 |
| escape | 3.8 | 6.9 | 0.55 |
| files | 3.8 | 6.9 | 0.55 |
| tuple_return_value | 3.8 | 6.9 | 0.55 |
| loops | 3.9 | 7.1 | 0.56 |
| containers | 28.6 | 47.8 | 0.60 |
| varargs | 5.5 | 6.9 | 0.79 |
Lower ratios are better.
| example name | C++ | Python | C++ : Python |
| asdl_generated | 0 | 8 | 0.000 |
| classes | 0 | 15 | 0.000 |
| control_flow | 0 | 8 | 0.000 |
| fib_recursive | 0 | 4 | 0.000 |
| files | 0 | 4 | 0.000 |
| modules | 0 | 8 | 0.000 |
| parse | 4 | 12 | 0.350 |
| containers | 12 | 28 | 0.419 |
| loops | 4 | 8 | 0.455 |
| scoped_resource | 8 | 12 | 0.660 |
| fib_iter | 4 | 4 | 0.946 |
| varargs | 51 | 52 | 0.973 |
| length | 8 | 4 | 2.040 |
| tuple_return_value | 10 | 4 | 2.521 |
| escape | 16 | 4 | 3.926 |
| cartesian | 8 | 0 | inf |
| cgi | 0 | 0 | NA |