mycpp Code Generation

Measure the speedup from mycpp, and the resource usage.

Source code: oil/mycpp/examples

User Time (milliseconds)

Lower ratios are better.

example name C++ Python C++ : Python
fib_recursive 60.1 988.1 0.061
scoped_resource 99.2 865.7 0.115
fib_iter 96.2 807.1 0.119
asdl_generated 96.2 394.1 0.244
loops 92.4 338.1 0.273
modules 76.3 222.6 0.343
cgi 211.7 553.8 0.382
containers 64.2 146.7 0.438
tuple_return_value 64.5 138.4 0.466
cartesian 549.9 731.8 0.751
escape 302.8 380.1 0.797
files 79.6 86.9 0.916
length 187.6 199.1 0.942
classes 63.8 36.5 1.748

Max Resident Set Size (MB)

Lower ratios are better. We use MB (powers of 10), not MiB (powers of 2).

example name C++ Python C++ : Python
containers 853.8 47.5 17.96
classes 841.8 7.3 115.07
loops 841.6 7.1 117.88
tuple_return_value 841.5 6.9 121.20
asdl_generated 841.4 6.9 121.34
scoped_resource 841.6 6.9 121.50
fib_iter 841.6 6.9 121.65
fib_recursive 841.6 6.9 121.65
files 861.6 7.1 121.87
modules 841.7 6.8 123.20
cgi 969.5 7.0 139.48
length 1,001.7 6.9 145.82
escape 1,103.9 6.9 160.43
cartesian 1,424.1 6.9 205.00

TODO