PR #12255: [GPU] Fix FMHA hangs by moving compilation to thunk initialization.
PR #12255: [GPU] Fix FMHA hangs by moving compilation to thunk initialization.

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

Applies the same fix as in https://github.com/openxla/xla/pull/12228 to FMHA.
Copybara import of the project:

--
70a42828f86711a0e83a2eb37ee52833e1768187 by Ilia Sergachev <isergachev@nvidia.com>:

[GPU] Fix FMHA hangs by moving compilation to thunk initialization.

Merging this change closes #12255

FUTURE_COPYBARA_INTEGRATE_REVIEW=https://github.com/openxla/xla/pull/12255 from openxla:fix_fmha_hang 70a42828f86711a0e83a2eb37ee52833e1768187
