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
gc_stack_roots gen 0 0 12 0.000
loops gen 0 3 292 0.000
modules gen 0 2 184 0.000
fib_iter gen 8 8 881 0.009
fib_recursive gen 11 7 890 0.012
asdl_generated gen 5 7 397 0.013
parse gen 23 19 769 0.029
containers gen 4 9 113 0.034
scoped_resource gen 46 42 1,048 0.044
tuple_return_value gen 19 15 189 0.101
classes gen 3 3 27 0.120
files gen 10 7 83 0.125
length gen 40 37 209 0.192
cartesian gen 91 78 342 0.266
escape gen 105 96 353 0.296
cgi gen 265 248 524 0.505
varargs gen 35 16 24 1.462
control_flow gen 206 159 119 1.727
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.5 4.5 12.2 0.37
parse gen 3.7 3.8 9.1 0.40
cartesian gen 3.5 3.5 8.5 0.42
gc_stack_roots gen 3.5 3.5 8.4 0.42
asdl_generated gen 3.7 3.7 8.5 0.43
scoped_resource gen 3.7 3.7 8.5 0.43
cgi gen 3.7 3.5 8.4 0.44
escape gen 3.7 3.7 8.4 0.44
fib_recursive gen 3.7 3.9 8.4 0.44
fib_iter gen 3.8 3.7 8.5 0.45
modules gen 3.8 3.5 8.5 0.45
length gen 3.8 3.8 8.4 0.45
loops gen 3.8 3.7 8.4 0.45
tuple_return_value gen 3.8 3.7 8.4 0.45
control_flow gen 3.9 3.9 8.5 0.46
files gen 3.9 3.8 8.5 0.46
containers gen 28.5 28.6 49.1 0.58
varargs gen 5.5 5.5 8.5 0.65
pea_hello gen NA NA 8.3 NA

System Time (milliseconds)

Lower ratios are better.

example name gen C++ C++-Souffle Python C++ : Python
cartesian gen 0 8 12 0.000
classes gen 0 0 11 0.000
escape gen 0 8 12 0.000
fib_iter gen 0 0 12 0.000
tuple_return_value gen 0 4 8 0.000
modules gen 2 0 12 0.151
gc_stack_roots gen 2 2 8 0.226
loops gen 4 0 16 0.230
length gen 4 8 12 0.339
containers gen 12 5 28 0.410
varargs gen 31 49 55 0.557
asdl_generated gen 5 4 8 0.674
parse gen 8 8 8 0.943
scoped_resource gen 4 4 4 0.961
cgi gen 4 4 4 1.003
control_flow gen 0 4 0 NA
fib_recursive gen 0 4 0 NA
files gen 0 0 0 NA
pea_hello gen NA NA 9 NA

raw benchmark files