title: first call to glDrawArrays is very slow on iPad
body: <p>I have an iPad app with UI written in OpenGL ES 2.0, some UI elements are hidden by default and when I need to show them there is pretty big delay before they actually shown (about 300-500 ms on a control which contains about 20 other controls inside), using Instruments.app I determined that when I render every unique object, it takes much longer to render it first time then after it was rendered at least once and the difference in rendering time is huge. Here is the code I have for rendering and this code is shown by Instruments taking all this delay:</p>
  
  <pre><code>- (void)render:(id &lt;ESRenderer&gt;)renderer
  {
      [shader useShader];
      glEnableVertexAttribArray(ATTRIB_VERTEX);
      glVertexAttribPointer(ATTRIB_VERTEX, 2, GL_FLOAT, 0, 0, _squareVertices);
      glEnableVertexAttribArray(ATTRIB_TEXTCOORD);
      glVertexAttribPointer(ATTRIB_TEXTCOORD, 2, GL_SHORT, 0, 0, coords);
      float x1 = self.position.x;
      float y1 = self.position.y;
      glUniform1f(shader.ext_uniforms[UNIFORM_TRANSLATE_X], -x1+_squareVertices[0]);
      glUniform1f(shader.ext_uniforms[UNIFORM_TRANSLATE_Y], -y1+_squareVertices[1]);
      glUniform1f(shader.ext_uniforms[UNIFORM_ROTATE], self.rotation); 
      glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
      glDisableVertexAttribArray(ATTRIB_VERTEX);
      glDisableVertexAttribArray(ATTRIB_TEXTCOORD);
  }
  </code></pre>
  
  <p>When it is called at least once it works perfectly fast.
  My shader is very simple too:</p>
  
  <pre><code>vec4 col = texture2D(texture, coordVarying);
  gl_FragColor = col;
  </code></pre>
  
  <p>Thanks!</p>