Add a Program::Data shared state structure.

Similar to the Framebuffer and other classes, this gives the Impl
class a read-only view of the object's state.

BUG=angleproject:1123

Change-Id: I580eaebe2de236adf8131d6e3f54633cecce8c25
Reviewed-on: https://chromium-review.googlesource.com/293760
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Tested-by: Jamie Madill <jmadill@chromium.org>
diff --git a/src/libANGLE/renderer/ProgramImpl.h b/src/libANGLE/renderer/ProgramImpl.h
index a160161..813324d 100644
--- a/src/libANGLE/renderer/ProgramImpl.h
+++ b/src/libANGLE/renderer/ProgramImpl.h
@@ -33,7 +33,7 @@
   public:
     typedef int SemanticIndexArray[gl::MAX_VERTEX_ATTRIBS];
 
-    ProgramImpl() { }
+    ProgramImpl(const gl::Program::Data &data);
     virtual ~ProgramImpl();
 
     virtual bool usesPointSize() const = 0;
@@ -87,8 +87,7 @@
     virtual void updateSamplerMapping() = 0;
     virtual bool validateSamplers(gl::InfoLog *infoLog, const gl::Caps &caps) = 0;
 
-    virtual LinkResult compileProgramExecutables(gl::InfoLog &infoLog, gl::Shader *fragmentShader, gl::Shader *vertexShader,
-                                                 int registers) = 0;
+    virtual LinkResult compileProgramExecutables(gl::InfoLog &infoLog, int registers) = 0;
 
     virtual bool linkUniforms(gl::InfoLog &infoLog, const gl::Shader &vertexShader, const gl::Shader &fragmentShader,
                               const gl::Caps &caps) = 0;
@@ -127,6 +126,8 @@
     virtual void reset();
 
   protected:
+    const gl::Program::Data &mData;
+
     std::vector<gl::LinkedUniform*> mUniforms;
 
     // TODO: use a hash map