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 937 0.008
modules gen 2 0 185 0.010
fib_recursive gen 11 11 897 0.012
loops gen 4 3 303 0.013
asdl_generated gen 7 11 400 0.018
parse gen 31 19 759 0.041
scoped_resource gen 43 37 1,037 0.042
tuple_return_value gen 15 19 194 0.080
files gen 8 8 76 0.099
containers gen 12 7 115 0.103
classes gen 3 3 23 0.141
length gen 44 38 214 0.208
gc_stack_roots gen 2 2 8 0.221
cartesian gen 84 81 356 0.236
escape gen 97 99 360 0.269
cgi gen 265 256 532 0.497
varargs gen 24 20 24 1.015
control_flow gen 205 157 129 1.593
pea_hello gen NA NA 15 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.6 4.5 12.5 0.37
gc_stack_roots gen 3.4 3.5 8.5 0.40
parse gen 3.7 3.8 9.0 0.41
escape gen 3.5 3.7 8.5 0.42
cartesian gen 3.7 3.7 8.5 0.43
cgi gen 3.7 3.7 8.5 0.43
files gen 3.7 3.8 8.5 0.43
length gen 3.7 3.7 8.4 0.44
loops gen 3.7 3.8 8.4 0.44
scoped_resource gen 3.7 3.8 8.4 0.44
asdl_generated gen 3.8 3.7 8.5 0.45
fib_iter gen 3.8 3.7 8.5 0.45
fib_recursive gen 3.8 3.7 8.4 0.45
tuple_return_value gen 3.8 3.8 8.4 0.45
modules gen 3.9 3.7 8.7 0.45
control_flow gen 3.9 3.7 8.4 0.47
containers gen 28.5 28.5 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
cgi gen 0 12 4 0.000
classes gen 0 0 15 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
length gen 0 8 4 0.000
loops gen 0 0 8 0.000
modules gen 0 2 12 0.000
parse gen 0 8 12 0.000
containers gen 4 7 28 0.143
control_flow gen 4 4 8 0.500
varargs gen 41 47 56 0.725
asdl_generated gen 4 0 4 0.909
tuple_return_value gen 4 0 4 0.956
cartesian gen 8 4 4 1.997
escape gen 8 4 4 2.018
scoped_resource gen 4 8 0 inf
pea_hello gen NA NA 4 NA

raw benchmark files