performance improvements to gemini