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 | 894 | 0.008 |
modules | gen | 2 | 173 | 0.010 |
loops | gen | 4 | 293 | 0.012 |
fib_recursive | gen | 11 | 879 | 0.013 |
asdl_generated | gen | 11 | 386 | 0.029 |
containers | gen | 4 | 106 | 0.036 |
parse | gen | 30 | 762 | 0.040 |
scoped_resource | gen | 43 | 1,036 | 0.042 |
files | gen | 4 | 68 | 0.053 |
tuple_return_value | gen | 20 | 202 | 0.100 |
classes | gen | 3 | 17 | 0.183 |
length | gen | 41 | 212 | 0.193 |
cartesian | gen | 82 | 340 | 0.241 |
escape | gen | 95 | 350 | 0.271 |
gc_stack_roots | gen | 2 | 4 | 0.407 |
cgi | gen | 261 | 515 | 0.506 |
varargs | gen | 16 | 13 | 1.241 |
control_flow | gen | 198 | 110 | 1.792 |
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.8 | 0.41 |
cartesian | gen | 3.5 | 7.1 | 0.50 |
gc_stack_roots | gen | 3.5 | 6.9 | 0.51 |
parse | gen | 3.9 | 7.6 | 0.52 |
modules | gen | 3.7 | 7.1 | 0.52 |
scoped_resource | gen | 3.7 | 7.1 | 0.52 |
asdl_generated | gen | 3.7 | 6.9 | 0.53 |
cgi | gen | 3.7 | 6.9 | 0.53 |
escape | gen | 3.7 | 6.9 | 0.53 |
fib_recursive | gen | 3.7 | 6.9 | 0.53 |
length | 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 |
tuple_return_value | gen | 3.8 | 6.8 | 0.56 |
control_flow | gen | 3.9 | 6.9 | 0.57 |
containers | gen | 28.7 | 47.8 | 0.60 |
varargs | gen | 5.5 | 7.1 | 0.78 |
Lower ratios are better.
example name | gen | C++ | Python | C++ : Python |
asdl_generated | gen | 0 | 4 | 0.000 |
classes | gen | 0 | 13 | 0.000 |
fib_iter | gen | 0 | 8 | 0.000 |
fib_recursive | gen | 0 | 4 | 0.000 |
gc_stack_roots | gen | 0 | 8 | 0.000 |
loops | gen | 0 | 4 | 0.000 |
modules | gen | 0 | 8 | 0.000 |
parse | gen | 0 | 12 | 0.000 |
tuple_return_value | gen | 0 | 4 | 0.000 |
containers | gen | 11 | 28 | 0.414 |
files | gen | 4 | 8 | 0.454 |
scoped_resource | gen | 4 | 8 | 0.539 |
cartesian | gen | 8 | 12 | 0.683 |
varargs | gen | 51 | 59 | 0.864 |
length | gen | 4 | 4 | 1.024 |
cgi | gen | 8 | 4 | 1.979 |
control_flow | gen | 8 | 4 | 2.007 |
escape | gen | 12 | 4 | 2.945 |