Code cleanup and rearranging to better utilize disk space.