Compiling my code with the -noboundscheck flag sped it up by almost 5 times (whilst passing all tests and working exactly the same way,) is bounds checking really that expensive, and what other simple optimisations can I preform other than -inline -O -noboundscheck?