PR #10858: [NVIDIA GPU] Enforce first collective permute of collective matmul to always run at the top of loop.
PR #10858: [NVIDIA GPU] Enforce first collective permute of collective matmul to always run at the top of loop.

Imported from GitHub PR https://github.com/openxla/xla/pull/10858

This is to port collective matmul related changes from this pr(https://github.com/openxla/xla/pull/10316).
We'd need the first collective permute of a collective matmul loop always run at the beginning of the loop.
We set the force_earliest_schedule flag  for that instruction to achieve so.
Force this schedule order would give about additional 3% speedup on top of existing collective matmul for GPT-3 530B model.
Copybara import of the project:

--
eb822e1493c0b0b51438f4b7153df6f9dfaa9276 by TJ Xu <tjx@nvidia.com>:

Enforce first collective permute of collective matmul to always run at
the top of loop.

Merging this change closes #10858

FUTURE_COPYBARA_INTEGRATE_REVIEW=https://github.com/openxla/xla/pull/10858 from Tixxx:tixxx/fixed_schedule_collective_matmul eb822e1493c0b0b51438f4b7153df6f9dfaa9276
