Measure the speedup from mycpp, and the resource usage.
Source code: oil/mycpp/examples
Lower ratios are better.
example name | C++ | Python | C++ : Python |
classes | 0 | 27 | 0.000 |
loops | 0 | 293 | 0.000 |
modules | 0 | 181 | 0.000 |
fib_iter | 8 | 894 | 0.009 |
fib_recursive | 11 | 880 | 0.012 |
parse | 19 | 793 | 0.023 |
asdl_generated | 11 | 375 | 0.029 |
containers | 4 | 117 | 0.034 |
scoped_resource | 43 | 1,010 | 0.043 |
tuple_return_value | 16 | 193 | 0.083 |
files | 7 | 68 | 0.110 |
length | 40 | 210 | 0.191 |
escape | 90 | 365 | 0.247 |
cartesian | 86 | 330 | 0.262 |
cgi | 265 | 509 | 0.520 |
varargs | 20 | 24 | 0.823 |
control_flow | 212 | 112 | 1.901 |
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.9 | 0.41 |
cartesian | 3.5 | 7.1 | 0.50 |
cgi | 3.5 | 7.1 | 0.50 |
parse | 3.8 | 7.3 | 0.52 |
asdl_generated | 3.7 | 6.9 | 0.53 |
fib_recursive | 3.8 | 7.1 | 0.54 |
length | 3.8 | 7.1 | 0.54 |
loops | 3.8 | 7.1 | 0.54 |
escape | 3.7 | 6.8 | 0.54 |
control_flow | 3.8 | 6.9 | 0.55 |
files | 3.8 | 6.9 | 0.55 |
modules | 3.8 | 6.9 | 0.55 |
scoped_resource | 3.8 | 6.9 | 0.55 |
tuple_return_value | 3.8 | 6.9 | 0.55 |
fib_iter | 3.9 | 6.9 | 0.57 |
containers | 28.4 | 47.8 | 0.59 |
varargs | 5.5 | 7.1 | 0.78 |
Lower ratios are better.
example name | C++ | Python | C++ : Python |
asdl_generated | 0 | 8 | 0.000 |
control_flow | 0 | 4 | 0.000 |
fib_iter | 0 | 4 | 0.000 |
fib_recursive | 0 | 12 | 0.000 |
files | 0 | 8 | 0.000 |
modules | 2 | 4 | 0.458 |
loops | 4 | 8 | 0.468 |
scoped_resource | 4 | 8 | 0.490 |
cgi | 4 | 8 | 0.500 |
containers | 12 | 23 | 0.503 |
cartesian | 4 | 8 | 0.512 |
classes | 3 | 5 | 0.725 |
varargs | 48 | 48 | 0.988 |
parse | 11 | 4 | 2.782 |
escape | 16 | 0 | inf |
length | 4 | 0 | inf |
tuple_return_value | 4 | 0 | inf |