try some simple loop optimizations(fix tabs)