Bunch of fixes and changes that make the program perform better from the last several months.