Some manual optimization.