r600g: fix TXD src regs needing fetching.
r600g: fix TXD src regs needing fetching.

[airlied: final chunk of Mike's patch from bug 37476
this uses a loop to emit the GRADIENTS and does a check to
see if we need to fetch to a temporary register. It also
increases the context src gpr to 4 which is needed here.]

Signed-off-by: Dave Airlie <f2295d84e358395675bc8031be58672073ae065e@redhat.com>

KTXSoftware/glsl2agal,mcanthony/glsl-optimizer,zeux/glsl-optimizer,benaadams/glsl-optimizer,dellis1972/glsl-optimizer,bkaradzic/glsl-optimizer,KTXSoftware/glsl2agal,dellis1972/glsl-optimizer,benaadams/glsl-optimizer,KTXSoftware/glsl2agal,jbarczak/glsl-optimizer,jbarczak/glsl-optimizer,tokyovigilante/glsl-optimizer,benaadams/glsl-optimizer,metora/MesaGLSLCompiler,adobe/glsl2agal,KTXSoftware/glsl2agal,bkaradzic/glsl-optimizer,zeux/glsl-optimizer,adobe/glsl2agal,adobe/glsl2agal,dellis1972/glsl-optimizer,wolf96/glsl-optimizer,mapbox/glsl-optimizer,mapbox/glsl-optimizer,mcanthony/glsl-optimizer,jbarczak/glsl-optimizer,benaadams/glsl-optimizer,adobe/glsl2agal,zeux/glsl-optimizer,mcanthony/glsl-optimizer,zz85/glsl-optimizer,zz85/glsl-optimizer,zz85/glsl-optimizer,wolf96/glsl-optimizer,tokyovigilante/glsl-optimizer,zz85/glsl-optimizer,wolf96/glsl-optimizer,djreep81/glsl-optimizer,mapbox/glsl-optimizer,bkaradzic/glsl-optimizer,zeux/glsl-optimizer,djreep81/glsl-optimizer,jbarczak/glsl-optimizer,KTXSoftware/glsl2agal,djreep81/glsl-optimizer,djreep81/glsl-optimizer,dellis1972/glsl-optimizer,adobe/glsl2agal,djreep81/glsl-optimizer,bkaradzic/glsl-optimizer,benaadams/glsl-optimizer,benaadams/glsl-optimizer,wolf96/glsl-optimizer,tokyovigilante/glsl-optimizer,jbarczak/glsl-optimizer,metora/MesaGLSLCompiler,mcanthony/glsl-optimizer,zz85/glsl-optimizer,bkaradzic/glsl-optimizer,tokyovigilante/glsl-optimizer,wolf96/glsl-optimizer,tokyovigilante/glsl-optimizer,dellis1972/glsl-optimizer,mcanthony/glsl-optimizer,mapbox/glsl-optimizer,zz85/glsl-optimizer,mapbox/glsl-optimizer,metora/MesaGLSLCompiler,zeux/glsl-optimizer