An LLVM pass that generates array checks on all array access and optimizes the overhead of the checks