A high level shader language compiler incorporates transforms to optimize
shader code for graphics processing hardware. An instruction reordering
transform determines instruction encapsulations of dependent instructions
that reduce concurrent register usage by the shader. A phase pulling
transform re-organizes the shader's instructions into phases that reduce
a measure of depth of texture loads. A register assigning transform
assigns registers to lower register usage by the shader.