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
fib_iter gen 8 4 899 0.008
modules gen 2 2 191 0.009
fib_recursive gen 11 7 886 0.012
loops gen 4 3 295 0.013
asdl_generated gen 11 11 385 0.028
containers gen 4 0 121 0.032
parse gen 30 27 768 0.040
scoped_resource gen 48 46 1,048 0.046
tuple_return_value gen 19 9 204 0.094
classes gen 3 3 35 0.094
files gen 7 7 71 0.104
gc_stack_roots gen 2 0 15 0.112
length gen 41 42 208 0.199
cartesian gen 84 78 333 0.252
escape gen 105 103 354 0.295
cgi gen 270 266 506 0.534
control_flow gen 204 159 118 1.732
varargs gen 27 12 15 1.787
pea_hello gen NA NA 14 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.5 4.5 12.3 0.36
gc_stack_roots gen 3.4 3.5 8.4 0.41
cgi gen 3.5 3.7 8.5 0.42
parse gen 3.8 3.8 9.1 0.42
scoped_resource gen 3.5 3.8 8.4 0.42
escape gen 3.7 3.7 8.5 0.43
modules gen 3.7 3.7 8.5 0.43
cartesian gen 3.7 3.7 8.4 0.44
fib_iter gen 3.8 3.8 8.5 0.45
fib_recursive gen 3.8 3.8 8.5 0.45
files gen 3.8 3.8 8.5 0.45
length gen 3.8 3.7 8.5 0.45
tuple_return_value gen 3.8 3.5 8.5 0.45
control_flow gen 3.8 3.7 8.4 0.45
loops gen 3.8 3.5 8.4 0.45
asdl_generated gen 3.8 3.7 8.3 0.46
containers gen 28.4 28.7 49.2 0.58
varargs gen 5.6 5.5 8.5 0.66
pea_hello gen NA NA 8.1 NA

System Time (milliseconds)

Lower ratios are better.

example name gen C++ C++-Souffle Python C++ : Python
asdl_generated gen 0 0 8 0.000
cgi gen 0 4 20 0.000
classes gen 0 0 4 0.000
escape gen 0 0 8 0.000
fib_iter gen 0 4 4 0.000
fib_recursive gen 0 4 12 0.000
files gen 0 0 12 0.000
gc_stack_roots gen 0 2 4 0.000
loops gen 0 0 8 0.000
modules gen 0 0 4 0.000
parse gen 0 0 16 0.000
scoped_resource gen 0 0 4 0.000
length gen 4 4 8 0.470
containers gen 12 13 20 0.573
varargs gen 39 54 65 0.601
cartesian gen 8 8 8 0.994
control_flow gen 4 4 4 1.019
pea_hello gen NA NA 4 NA
tuple_return_value gen 0 9 0 NA

raw benchmark files