mesa: replace ctx->Const.{Vertex,Fragment,Geomtery}Program with an array.

These are replaced with
ctx->Const.Program[MESA_SHADER_{VERTEX,FRAGMENT,GEOMETRY}].  In the
patch to follow, this will allow us to replace a lot of ad-hoc logic
with a variable index into the array.

With the exception of the changes to mtypes.h, this patch was
generated entirely by the command:

    find src -type f '(' -iname '*.c' -o -iname '*.cpp' -o -iname '*.py' \
    -o -iname '*.y' ')' -print0 | xargs -0 sed -i \
    -e 's/Const\.VertexProgram/Const.Program[MESA_SHADER_VERTEX]/g' \
    -e 's/Const\.GeometryProgram/Const.Program[MESA_SHADER_GEOMETRY]/g' \
    -e 's/Const\.FragmentProgram/Const.Program[MESA_SHADER_FRAGMENT]/g'
======= BEGIN ARB_compute_shader work =======
mesa: Make validate_shader_target() non-static.
mesa: use _mesa_validate_shader_target() more frequently.

This patch replaces code in _mesa_new_shader() and delete_shader_cb()
that checks the type of a shader with calls to
_mesa_validate_shader_target().  This has two advantages: it allows
for a more thorough check (since _mesa_validate_shader_target()
doesn't permit shader targets that aren't supported by the back-end),
and it reduces the amount of code that will need to be modified when
adding new shader stages.
glsl: Change some linker loops to use MESA_SHADER_FRAGMENT as a bound.

Linker loops that iterate through all the stages in the pipeline need
to use MESA_SHADER_FRAGMENT as a bound, so that we can add an
additional MESA_SHADER_COMPUTE stage, without it being erroneously
included in the pipeline.
glsl/linker: Refactor in preparation for adding more shader stages.

Rather than maintain separately named arrays and counts for vertex,
geometry, and fragment shaders, just maintain these as arrays indexed
by the gl_shader_type enum.
mesa: Replace Current{Vertex,Geometry,Fragment}Program with array.

This should make it easier to add additional shader types
(e.g. compute shaders).
mesa: Add extension enable flags for ARB_compute_shader.
mesa: Implement MAX_COMPUTE_WORK_GROUP_SIZE constant.
mesa: Add dispatch API stubs for ARB_compute_shader.
mesa: Implement MAX_COMPUTE_WORK_GROUP_INVOCATIONS constant.
WIP: glsl: Add parser support for compute shader layout qualifiers.
mesa: Add a MESA_SHADER_COMPUTE stage.
i965: Allow ARB_compute_shader to be enabled via env var.

This will allow testing of compute shader functionality before it is
completed.
glsl: Handle compute shader local_size_{x,y,z} declaration.
WIP: update switch statements etc
WIP: implement generate_cs_special_vars()
mesa: Create the gl_compute_program struct, and the code to initialize it.
Fix another switch statement.
i965: Create the brw_compute_program struct, and the code to initialize it.