https://github.com/cor3ntin approved this pull request. I think there is an opportunity for a small refactor here, but feel free to land this and we can handle the refactor later as an NFC change if you prefer https://github.com/llvm/llvm-project/pull/68506