Make functions inline to reduce effect of function calls