Benchmark Trilinear interpolation

I do a performance benchmark with a function that takes a lot of CPU time in my game which is a Trilinear interpolation function. This is used while generating voxel world.

Results (x86) for a 256x256x256 voxels array on Core I7 at 3.60 Ghz :

  • BlitzMax (GCC -O3 optimization) -> 112 ms
  • C++ (VS2015) -> 203 ms
  • C# .Net Native¬† -> 203 ms
  • BlitzMax (GCC -O2 optimization) -> 215 ms
  • C# .NetCore v1.0 RC2 -> 281 ms
  • C# .NetFramework v4.6.1 -> 422 ms
  • C# Mono 4.4 (-O=All) -> 625 ms

Results (ARM) for a 256x256x256 voxels array on Raspberry Pi 2 :

  • C++ (GCC -O3 optimization) -> 2762 ms
  • C# Mono 4.6.1 (-O=all -O=float32) -> 10702 ms

.Net Native for windows universal application is as fast as C++ and OpenSource .NetCore is very promising…

GCC is faster than MS compiler for my bench, good news for BlitzMax.

Source Code Here