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 3 28 0.000
containers gen 0 15 116 0.000
fib_iter gen 8 8 891 0.008
modules gen 2 2 182 0.010
fib_recursive gen 11 11 877 0.012
loops gen 4 3 283 0.013
asdl_generated gen 7 11 375 0.019
scoped_resource gen 35 42 1,056 0.034
parse gen 26 28 749 0.035
files gen 7 7 68 0.108
tuple_return_value gen 20 15 183 0.112
length gen 37 42 197 0.186
cartesian gen 84 83 320 0.263
escape gen 105 100 353 0.296
cgi gen 248 260 499 0.497
varargs gen 21 19 16 1.290
control_flow gen 205 161 101 2.041
gc_stack_roots gen 2 2 0 inf

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.3 4.5 10.8 0.40
parse gen 3.8 3.8 7.6 0.50
asdl_generated gen 3.5 3.7 6.9 0.51
cartesian gen 3.5 3.7 6.9 0.51
cgi gen 3.5 3.7 6.9 0.51
escape gen 3.5 3.7 6.9 0.51
gc_stack_roots gen 3.5 3.4 6.9 0.51
loops gen 3.8 3.8 7.2 0.53
fib_recursive gen 3.7 3.8 6.9 0.53
files gen 3.7 3.8 6.9 0.53
scoped_resource gen 3.7 3.8 6.9 0.53
length gen 3.8 3.8 7.1 0.54
fib_iter gen 3.8 3.8 6.9 0.55
modules gen 3.8 3.7 6.9 0.55
control_flow gen 3.9 3.8 6.9 0.57
tuple_return_value gen 3.9 3.7 6.9 0.57
containers gen 28.7 28.4 47.6 0.60
varargs gen 5.5 5.5 6.9 0.79

System Time (milliseconds)

Lower ratios are better.

example name gen C++ C++-Souffle Python C++ : Python
control_flow gen 0 0 15 0.000
escape gen 0 4 4 0.000
fib_iter gen 0 0 4 0.000
fib_recursive gen 0 0 8 0.000
files gen 0 0 8 0.000
gc_stack_roots gen 0 0 12 0.000
loops gen 0 0 12 0.000
modules gen 0 0 4 0.000
tuple_return_value gen 0 4 12 0.000
parse gen 4 0 12 0.316
asdl_generated gen 4 0 8 0.447
length gen 8 4 12 0.688
containers gen 16 0 20 0.780
varargs gen 45 47 56 0.811
classes gen 3 0 4 0.815
cartesian gen 8 4 8 1.001
cgi gen 8 8 8 1.003
scoped_resource gen 12 4 0 inf

raw benchmark files