Layout optimization.