Optimize layout of class members.