optimizations/getting stuff ready