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 8 885 0.009
modules gen 2 2 183 0.011
fib_recursive gen 11 11 871 0.012
loops gen 4 3 294 0.013
asdl_generated gen 7 11 378 0.019
parse gen 30 18 760 0.039
scoped_resource gen 48 42 1,028 0.046
containers gen 8 11 122 0.063
tuple_return_value gen 16 15 186 0.086
files gen 8 4 68 0.113
classes gen 3 3 24 0.136
length gen 41 40 204 0.199
gc_stack_roots gen 2 0 8 0.224
cartesian gen 87 84 347 0.252
escape gen 106 99 344 0.309
cgi gen 265 245 512 0.518
varargs gen 29 8 23 1.249
control_flow gen 209 158 107 1.949

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 10.7 0.41
gc_stack_roots gen 3.4 3.4 6.9 0.49
cartesian gen 3.5 3.5 7.1 0.50
parse gen 3.8 3.8 7.5 0.51
asdl_generated gen 3.5 3.8 6.9 0.51
escape gen 3.5 3.5 6.9 0.51
fib_iter gen 3.5 3.8 6.9 0.51
cgi gen 3.7 3.7 6.9 0.53
fib_recursive gen 3.7 3.7 6.9 0.53
files gen 3.8 3.8 7.1 0.54
scoped_resource gen 3.8 3.5 7.1 0.54
length gen 3.7 3.8 6.8 0.54
control_flow gen 3.8 3.8 6.9 0.55
loops gen 3.8 3.8 6.9 0.55
modules gen 3.8 3.8 6.9 0.55
tuple_return_value gen 3.8 3.7 6.9 0.55
containers gen 28.6 28.7 47.6 0.60
varargs gen 5.4 5.5 6.9 0.77

System Time (milliseconds)

Lower ratios are better.

example name gen C++ C++-Souffle Python C++ : Python
classes gen 0 0 8 0.000
control_flow gen 0 4 8 0.000
escape gen 0 8 8 0.000
fib_iter gen 0 0 12 0.000
fib_recursive gen 0 0 12 0.000
files gen 0 4 8 0.000
gc_stack_roots gen 0 2 4 0.000
loops gen 0 0 4 0.000
modules gen 0 0 4 0.000
parse gen 0 9 8 0.000
scoped_resource gen 0 4 16 0.000
containers gen 8 4 20 0.380
cartesian gen 4 0 8 0.493
tuple_return_value gen 4 4 8 0.496
cgi gen 4 8 8 0.502
length gen 4 4 8 0.508
varargs gen 37 58 50 0.741
asdl_generated gen 4 0 4 0.914

raw benchmark files