Fixed a few bugs and added compression to 1st pass files