Add a utility for finding HLO use chains
Add a utility for finding HLO use chains

This is needed for proper epilogue indexing computations, e.g.
in fusions like this:

```
          reduce
         /      \
   broadcast    log
        |        |
       neg    bitcast
         \      /
           ROOT
```

The current assumption in `ComputeEpilogueInputToOutputIndexing`
that we can just take the first user is incorrect here - the
reduce is both part of the side output's computation and the hero
of the fusion. Fusions like this make absolutely no sense, but they
exist.

FUTURE_COPYBARA_INTEGRATE_REVIEW=https://github.com/tensorflow/tensorflow/pull/61773 from Intel-tensorflow:kanvi/remove_stopgradient dcc39ce50742700042f8a89b9a48dce320057ffe
