some speed inprovments