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 gen C++ C++-Souffle Python C++ : Python
classes gen 0 0 27 0.000
gc_stack_roots gen 0 2 8 0.000
fib_iter gen 8 8 889 0.009
modules gen 2 0 184 0.010
fib_recursive gen 11 11 895 0.012
loops gen 4 0 305 0.012
asdl_generated gen 5 7 382 0.014
parse gen 27 27 791 0.034
scoped_resource gen 40 45 1,033 0.039
tuple_return_value gen 19 18 208 0.092
files gen 7 8 76 0.096
containers gen 12 15 119 0.100
length gen 45 46 214 0.209
cartesian gen 80 74 340 0.234
escape gen 100 90 357 0.280
cgi gen 265 267 528 0.501
varargs gen 27 15 32 0.847
control_flow gen 211 164 113 1.876
pea_hello gen NA NA 9 NA

Max Resident Set Size (MB)

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

example name gen C++ C++-Souffle Python C++ : Python
classes gen 4.6 4.5 12.2 0.38
escape gen 3.5 3.7 8.5 0.42
parse gen 3.8 3.8 9.1 0.42
asdl_generated gen 3.5 3.5 8.4 0.42
cgi gen 3.5 3.7 8.4 0.42
gc_stack_roots gen 3.5 3.4 8.4 0.42
cartesian gen 3.7 3.7 8.5 0.43
scoped_resource gen 3.7 3.8 8.5 0.43
files gen 3.7 3.8 8.4 0.44
tuple_return_value gen 3.7 3.8 8.4 0.44
loops gen 3.8 3.7 8.5 0.45
modules gen 3.8 3.8 8.5 0.45
control_flow gen 3.8 3.9 8.4 0.45
fib_iter gen 3.8 3.8 8.4 0.45
fib_recursive gen 3.8 3.8 8.4 0.45
length gen 3.9 3.8 8.5 0.46
containers gen 28.4 28.3 48.9 0.58
varargs gen 5.5 5.6 8.1 0.68
pea_hello gen NA NA 8.3 NA

System Time (milliseconds)

Lower ratios are better.

example name gen C++ C++-Souffle Python C++ : Python
control_flow gen 0 0 8 0.000
fib_iter gen 0 0 8 0.000
fib_recursive gen 0 0 12 0.000
files gen 0 0 8 0.000
length gen 0 0 4 0.000
loops gen 0 3 8 0.000
modules gen 0 2 20 0.000
tuple_return_value gen 0 0 12 0.000
containers gen 4 0 28 0.143
gc_stack_roots gen 2 0 12 0.154
classes gen 3 3 12 0.284
escape gen 4 12 12 0.336
asdl_generated gen 5 4 12 0.450
scoped_resource gen 8 0 12 0.671
varargs gen 39 50 48 0.806
parse gen 4 0 4 0.969
cgi gen 4 0 4 0.987
cartesian gen 12 12 12 0.994
pea_hello gen NA NA 9 NA

raw benchmark files