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 31 0.000
containers gen 0 7 117 0.000
loops gen 0 3 298 0.000
fib_iter gen 4 8 891 0.004
modules gen 2 2 183 0.011
fib_recursive gen 11 11 896 0.012
asdl_generated gen 11 11 373 0.029
scoped_resource gen 39 38 1,042 0.038
parse gen 30 27 767 0.039
files gen 4 7 76 0.049
tuple_return_value gen 19 15 184 0.105
gc_stack_roots gen 2 2 12 0.147
length gen 40 42 214 0.188
cartesian gen 87 81 348 0.249
escape gen 92 99 359 0.255
cgi gen 257 253 516 0.498
varargs gen 21 24 36 0.572
control_flow gen 209 161 120 1.742
pea_hello gen NA NA 4 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.3 4.5 12.5 0.35
gc_stack_roots gen 3.4 3.4 8.4 0.41
asdl_generated gen 3.5 3.7 8.4 0.42
cgi gen 3.7 3.7 8.5 0.43
control_flow gen 3.7 3.9 8.5 0.43
escape gen 3.7 3.8 8.5 0.43
loops gen 3.7 3.8 8.5 0.43
cartesian gen 3.7 3.7 8.4 0.44
fib_recursive gen 3.7 3.8 8.4 0.44
length gen 3.7 3.8 8.4 0.44
scoped_resource gen 3.7 3.8 8.4 0.44
parse gen 3.9 3.8 9.0 0.44
modules gen 3.8 3.5 8.7 0.44
files gen 3.8 3.8 8.5 0.45
fib_iter gen 3.8 3.7 8.4 0.45
tuple_return_value gen 3.9 3.8 8.4 0.47
containers gen 28.4 28.6 49.1 0.58
varargs gen 5.5 5.5 8.5 0.65
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 16 0.000
fib_recursive gen 0 0 8 0.000
gc_stack_roots gen 0 0 8 0.000
modules gen 0 0 12 0.000
parse gen 0 0 8 0.000
tuple_return_value gen 0 4 16 0.000
fib_iter gen 4 0 12 0.314
cartesian gen 4 4 12 0.328
classes gen 3 0 8 0.415
loops gen 4 0 8 0.460
files gen 4 0 8 0.463
length gen 4 4 8 0.498
containers gen 16 7 24 0.640
scoped_resource gen 8 8 8 0.979
cgi gen 12 0 12 0.988
varargs gen 45 43 44 1.029
escape gen 12 4 4 2.999
control_flow gen 4 0 0 inf
pea_hello gen NA NA 15 NA

raw benchmark files