[Mosaic GPU] Implement the fully general txmatrix transfer planning
The new method is pretty powerful and is guaranteed to emit at most one
num=2 and at most one num=1 transfer per each tiled dimension (and only
if no tiled dimension is even).
PiperOrigin-RevId: 945670904