Speedup by using a tmp variable.