I'm not sure I understand what straight-line code is. Does it just mean no conditionals (`if`, `&&`, `||`, `a ? b : c`) or possible exceptions, in the loop body or functions called from the loop. Because of this you need to wrap all array accesses in `@inbounds` to suppress the conditional to raise a `BoundsError`?.