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
modules gen 0 2 194 0.000
fib_iter gen 8 4 937 0.008
fib_recursive gen 7 11 891 0.008
loops gen 4 3 295 0.012
asdl_generated gen 11 11 396 0.027
parse gen 30 23 780 0.039
scoped_resource gen 44 41 1,047 0.042
tuple_return_value gen 12 18 192 0.060
files gen 7 4 79 0.092
containers gen 10 3 100 0.103
classes gen 3 0 23 0.138
gc_stack_roots gen 2 2 12 0.144
length gen 44 45 209 0.212
escape gen 89 99 354 0.251
cartesian gen 86 82 338 0.255
cgi gen 265 263 530 0.500
varargs gen 12 24 16 0.768
control_flow gen 212 163 110 1.934
pea_hello gen NA NA 5 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.2 0.36
gc_stack_roots gen 3.4 3.4 8.4 0.41
modules gen 3.5 3.8 8.5 0.42
parse gen 3.8 3.8 9.1 0.42
length gen 3.7 3.7 8.5 0.43
tuple_return_value gen 3.7 3.8 8.5 0.43
asdl_generated gen 3.7 3.7 8.4 0.44
cartesian gen 3.7 3.5 8.4 0.44
cgi gen 3.7 3.5 8.4 0.44
escape gen 3.7 3.7 8.4 0.44
fib_iter gen 3.8 3.8 8.5 0.45
files gen 3.8 3.8 8.5 0.45
scoped_resource gen 3.8 3.5 8.5 0.45
control_flow gen 3.8 3.8 8.4 0.45
fib_recursive gen 3.8 3.7 8.4 0.45
loops gen 3.8 3.8 8.4 0.45
containers gen 28.4 28.7 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
classes gen 0 3 16 0.000
control_flow gen 0 0 12 0.000
fib_iter gen 0 4 4 0.000
files gen 0 4 4 0.000
gc_stack_roots gen 0 0 8 0.000
length gen 0 0 12 0.000
loops gen 0 0 8 0.000
parse gen 0 4 12 0.000
containers gen 5 10 44 0.117
modules gen 2 0 4 0.444
scoped_resource gen 4 4 8 0.499
cartesian gen 4 4 8 0.510
varargs gen 53 41 64 0.832
fib_recursive gen 4 0 4 0.896
tuple_return_value gen 8 0 8 0.961
cgi gen 4 4 4 0.992
escape gen 16 4 8 2.031
asdl_generated gen 0 0 0 NA
pea_hello gen NA NA 14 NA

raw benchmark files