Rendering code optimizations.