This is a move-only commit, best reviewed with
```
git show --color-moved=dimmed_zebra --color-moved-ws=allow-indentation-change
```
This concludes backport of core#25500
https://github.com/bitcoin/bitcoin/pull/25500/commits/c741d748d4d9836940b99091cc7be09c65efcb79
https://github.com/bitcoin/bitcoin/pull/25500/commits/0101d2bc3c3bcf698d6cc2a237a680fc52395987
Depends on D18242