glsl: fix indexing order of 2D arrays

My original implementation of 2D arrays switched the vertex and attribute
indices in dereferencing.  This commit fixes that, and as a side effect makes
the code somewhat cleaner.

This could be combined with "glsl: support compilation of geometry shaders
via EXT/ARB_geometry_shader4" to make the patch set cleaner.
glsl_to_tgsi: fix 2D array indexing order

This fixes glsl_to_tgsi in accordance with the changes in the previous patch.

This could be merged into the commit "st/mesa, glsl_to_tgsi: add support for
geometry shaders" to make the patch set cleaner.
glsl: allow interpolation qualifiers in geometry shaders

This patch could be merged with the commit "glsl: support compilation of
geometry shaders via EXT/ARB_geometry_shader4" to make the patch set cleaner.
mesa: make transform feedback use the geometry shader if one is active
nv50/ir: fix PFETCH and add RDSV to get VSTRIDE for GPs

v2 (Bryan Cain <bryancain3@gmail.com>): Fix emission of PFETCH instructions
using the SHL form.
nv50: add support for geometry shaders

Layer output probably doesn't work yet, but other than that everything seems
to be working.