Use optimized loop