Unity performance optimization