SjoerdMeijer added a comment. Yes, interesting. LoopVersioningLICM came to my mind, except that works on loops of course... Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102834/new/ https://reviews.llvm.org/D102834