Codon VS Haxe benchmarks

Current benchmark data was generated on Tue Jul 01 2025, full log can be found HERE

CONTRIBUTIONS are WELCOME!

[x86_64][4 cores] AMD EPYC 7763 64-Core Processor (Model 1)

* -m in a file name stands for multi-threading or multi-processing

* -i in a file name stands for direct intrinsics usage. (Usage of simd intrinsics via libraries is not counted)

* -ffi in a file name stands for non-stdlib FFI usage

* (You may find time < time(user) + time(sys) for some non-parallelized programs, the overhead is from GC or JIT compiler, which are allowed to take advantage of multi-cores as that's more close to real-world scenarios.)

helloworld

Input: QwQ

lang code time stddev peak-mem mem time(user) time(sys) compiler compiler/runtime
haxe 1.hx 1.8ms 0.1ms 2.9MB 0ms 0ms haxe/hl/c 4.3.6
haxe 1.hx 2.2ms 0.2ms 4.4MB 0ms 0ms haxe/cpp 4.3.6
haxe 1.hx 3.3ms 0.1ms 2.8MB 0ms 0ms haxe/hl/jit 1.16.0
codon 1-m.py 11ms 0.6ms 8.5MB 20ms 0ms codon 0.19.0

nbody

Input: 5000000

lang code time stddev peak-mem mem time(user) time(sys) compiler compiler/runtime
haxe 2.hx 870ms 25ms 3.0MB 860ms 0ms haxe/hl/c 4.3.6
haxe 1.hx 1072ms 15ms 3.0MB 1063ms 0ms haxe/hl/c 4.3.6
codon 1.py 1325ms 2.3ms 9.4MB 1630ms 0ms codon 0.19.0
haxe 3.hx 1407ms 15ms 25.6MB 1640ms 33ms haxe/cpp 4.3.6
haxe 2.hx 2409ms 10ms 3.8MB 2400ms 0ms haxe/hl/jit 1.16.0
haxe 1.hx 2472ms 13ms 3.6MB 2463ms 0ms haxe/hl/jit 1.16.0
haxe 1.hx timeout 0.0ms 4.4MB 4990ms 0ms haxe/cpp 4.3.6
haxe 2.hx timeout 0.0ms 4.4MB 4990ms 0ms haxe/cpp 4.3.6
haxe 3.hx timeout 0.0ms 3.4MB 3940ms 1563ms haxe/hl/c 4.3.6
haxe 3.hx timeout 0.0ms 3.8MB 4113ms 1343ms haxe/hl/jit 1.16.0

Input: 500000

lang code time stddev peak-mem mem time(user) time(sys) compiler compiler/runtime
haxe 2.hx 90ms 1.5ms 3.0MB 80ms 0ms haxe/hl/c 4.3.6
haxe 1.hx 112ms 4.0ms 3.0MB 103ms 0ms haxe/hl/c 4.3.6
haxe 3.hx 158ms 2.9ms 25.6MB 163ms 10ms haxe/cpp 4.3.6
codon 1-m.py 173ms 4.4ms 9.4MB 483ms 0ms codon 0.19.0
haxe 2.hx 247ms 0.8ms 3.6MB 240ms 0ms haxe/hl/jit 1.16.0
haxe 1.hx 253ms 3.2ms 3.6MB 243ms 0ms haxe/hl/jit 1.16.0
haxe 2.hx 681ms 16ms 4.4MB 670ms 0ms haxe/cpp 4.3.6
haxe 3.hx 744ms 120ms 3.1MB 603ms 197ms haxe/hl/c 4.3.6
haxe 3.hx 793ms 3.6ms 3.8MB 663ms 190ms haxe/hl/jit 1.16.0
haxe 1.hx 806ms 1.4ms 4.4MB 797ms 0ms haxe/cpp 4.3.6

nsieve

Input: 12

lang code time stddev peak-mem mem time(user) time(sys) compiler compiler/runtime
codon 1-m.py 409ms 6.0ms 48.6MB 697ms 3ms codon 0.19.0
codon 2.py 913ms 1.4ms 100.8MB 1220ms 23ms codon 0.19.0

Input: 10

lang code time stddev peak-mem mem time(user) time(sys) compiler compiler/runtime
codon 1-m.py 117ms 2.3ms 19.4MB 427ms 0ms codon 0.19.0
codon 2-m.py 233ms 3.4ms 27.7MB 543ms 7ms codon 0.19.0