Move some code into performance sub package