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 | 292 | 0.000 |
modules | 0 | 179 | 0.000 |
fib_iter | 8 | 888 | 0.009 |
fib_recursive | 11 | 884 | 0.013 |
asdl_generated | 8 | 392 | 0.019 |
parse | 30 | 759 | 0.039 |
scoped_resource | 47 | 1,066 | 0.044 |
files | 4 | 68 | 0.054 |
containers | 12 | 111 | 0.108 |
tuple_return_value | 20 | 184 | 0.109 |
classes | 3 | 23 | 0.140 |
length | 40 | 207 | 0.193 |
cartesian | 67 | 323 | 0.207 |
escape | 107 | 344 | 0.312 |
cgi | 268 | 512 | 0.524 |
varargs | 17 | 16 | 1.035 |
control_flow | 208 | 106 | 1.962 |
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.7 | 0.41 |
parse | 3.8 | 7.6 | 0.50 |
length | 3.7 | 7.1 | 0.52 |
tuple_return_value | 3.7 | 7.1 | 0.52 |
loops | 3.8 | 7.2 | 0.53 |
asdl_generated | 3.7 | 6.9 | 0.53 |
cartesian | 3.7 | 6.9 | 0.53 |
cgi | 3.7 | 6.9 | 0.53 |
escape | 3.7 | 6.9 | 0.53 |
modules | 3.7 | 6.9 | 0.53 |
scoped_resource | 3.7 | 6.9 | 0.53 |
control_flow | 3.8 | 6.9 | 0.55 |
fib_iter | 3.8 | 6.9 | 0.55 |
fib_recursive | 3.8 | 6.9 | 0.55 |
files | 3.8 | 6.9 | 0.55 |
containers | 28.4 | 47.8 | 0.59 |
varargs | 5.6 | 7.1 | 0.80 |
Lower ratios are better.
example name | C++ | Python | C++ : Python |
cgi | 0 | 4 | 0.000 |
classes | 0 | 8 | 0.000 |
control_flow | 0 | 8 | 0.000 |
escape | 0 | 8 | 0.000 |
fib_iter | 0 | 4 | 0.000 |
fib_recursive | 0 | 8 | 0.000 |
parse | 0 | 12 | 0.000 |
scoped_resource | 0 | 12 | 0.000 |
tuple_return_value | 0 | 8 | 0.000 |
containers | 4 | 28 | 0.144 |
asdl_generated | 4 | 12 | 0.314 |
modules | 2 | 4 | 0.459 |
files | 4 | 8 | 0.462 |
varargs | 50 | 56 | 0.888 |
loops | 4 | 4 | 0.929 |
length | 4 | 4 | 1.005 |
cartesian | 24 | 12 | 1.973 |