Simplify inner loop of reductions/ preformance boost