[XLA:GPU] Replace dynamic-slice with slice during autotuning
[XLA:GPU] Replace dynamic-slice with slice during autotuning

Dynamic slice requires specific values for the indices that it takes in as operands. However, under computation extraction in the autotuner, all operands are replaced with random parameter values (which then represent incorrect/invalid offsets.) In order to avoid this, we replace dynamic-slice instructions with static slice instructions indexed at 0 along all dimensions.

This CL is needed for a later CL which will add support for fusing dynamic-slice into triton fusions.

The original author of this CL is jvstokes and I rewrote it a bit.

FUTURE_COPYBARA_INTEGRATE_REVIEW=https://github.com/openxla/xla/pull/12161 from jaro-sevcik:serialize-as-stream-executor-executable 818765f7b1f5f7282d3f2756b2a03ac556201a6c
