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 | 23 | 0.000 |
fib_recursive | 7 | 891 | 0.008 |
fib_iter | 8 | 877 | 0.009 |
modules | 2 | 184 | 0.010 |
loops | 4 | 296 | 0.013 |
asdl_generated | 7 | 378 | 0.019 |
parse | 25 | 773 | 0.032 |
scoped_resource | 43 | 1,042 | 0.042 |
containers | 8 | 101 | 0.079 |
files | 7 | 72 | 0.102 |
tuple_return_value | 20 | 182 | 0.109 |
length | 41 | 199 | 0.205 |
cartesian | 79 | 324 | 0.243 |
escape | 102 | 340 | 0.300 |
cgi | 255 | 513 | 0.496 |
varargs | 23 | 20 | 1.174 |
control_flow | 213 | 111 | 1.925 |
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.6 | 0.42 |
parse | 3.8 | 7.6 | 0.50 |
control_flow | 3.7 | 7.1 | 0.52 |
scoped_resource | 3.7 | 7.1 | 0.52 |
cartesian | 3.5 | 6.8 | 0.52 |
cgi | 3.7 | 6.9 | 0.53 |
asdl_generated | 3.8 | 7.1 | 0.54 |
escape | 3.8 | 7.1 | 0.54 |
loops | 3.8 | 7.1 | 0.54 |
modules | 3.8 | 7.1 | 0.54 |
fib_iter | 3.8 | 6.9 | 0.55 |
fib_recursive | 3.8 | 6.9 | 0.55 |
tuple_return_value | 3.8 | 6.9 | 0.55 |
files | 3.9 | 7.1 | 0.56 |
length | 3.9 | 6.9 | 0.57 |
containers | 28.5 | 47.7 | 0.60 |
varargs | 5.5 | 7.1 | 0.78 |
Lower ratios are better.
example name | C++ | Python | C++ : Python |
cgi | 0 | 8 | 0.000 |
control_flow | 0 | 4 | 0.000 |
fib_iter | 0 | 12 | 0.000 |
files | 0 | 4 | 0.000 |
loops | 0 | 4 | 0.000 |
modules | 0 | 4 | 0.000 |
tuple_return_value | 0 | 8 | 0.000 |
containers | 8 | 32 | 0.246 |
fib_recursive | 4 | 12 | 0.312 |
length | 4 | 12 | 0.342 |
parse | 4 | 12 | 0.347 |
classes | 3 | 8 | 0.422 |
asdl_generated | 4 | 8 | 0.452 |
escape | 4 | 8 | 0.491 |
scoped_resource | 4 | 8 | 0.494 |
varargs | 43 | 52 | 0.828 |
cartesian | 12 | 4 | 2.952 |