Major preformance improvements